From 28314b06df803219263b6c1f48817b33dee0960f Mon Sep 17 00:00:00 2001 From: EnRoute Date: Mon, 14 Aug 2017 04:41:45 +0300 Subject: [PATCH] feat(types): Change signature of IntType constructor. --- src/types/int.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/types/int.js b/src/types/int.js index f142406..e647ee2 100644 --- a/src/types/int.js +++ b/src/types/int.js @@ -3,8 +3,8 @@ import NumberType from './number'; const { round, abs } = Math; class IntType extends NumberType { - constructor(min, max) { - super(min, max); + constructor({ min, max } = {}) { + super({ min, max }); this.validators.push(val => (abs(val) - round(abs(val))) === 0); }