Fixed the tests
This commit is contained in:
parent
7815fb2dc3
commit
eb695a1c91
1 changed files with 20 additions and 20 deletions
|
@ -143,7 +143,7 @@ export const number = (
|
|||
)} given.`,
|
||||
)
|
||||
}
|
||||
if (typeof opts === 'object' && opts) {
|
||||
if (typeof opts === 'object' && opts !== null) {
|
||||
if (Object.prototype.hasOwnProperty.call(opts, 'range')) {
|
||||
if (!Array.isArray(opts.range)) {
|
||||
throw new Error(
|
||||
|
@ -163,7 +163,6 @@ export const number = (
|
|||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
if (Object.prototype.hasOwnProperty.call(opts, 'nudgeMultiplier')) {
|
||||
if (
|
||||
typeof opts!.nudgeMultiplier !== 'number' ||
|
||||
|
@ -186,6 +185,7 @@ export const number = (
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return {
|
||||
type: 'number',
|
||||
valueType: 0,
|
||||
|
|
Loading…
Reference in a new issue