async-validator
Advanced tools
Comparing version 1.5.0 to 1.5.1
@@ -9,2 +9,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
var _rule = require('../rule/'); | ||
@@ -28,3 +30,3 @@ | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
var ENUM = 'enum'; | ||
@@ -30,3 +32,3 @@ | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -33,0 +35,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
/** | ||
@@ -28,3 +30,3 @@ * Validates a number is a floating point number. | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
/** | ||
@@ -28,3 +30,3 @@ * Validates a number is an integer. | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
/** | ||
@@ -28,3 +30,3 @@ * Validates a function. | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
/** | ||
@@ -28,3 +30,3 @@ * Validates a number. | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
@@ -13,2 +13,4 @@ 'use strict'; | ||
var _util = require('../util'); | ||
/** | ||
@@ -28,3 +30,3 @@ * Validates an object. | ||
if (validate) { | ||
if (value === undefined && !rule.required) { | ||
if ((0, _util.isEmptyValue)(value) && !rule.required) { | ||
return callback(); | ||
@@ -31,0 +33,0 @@ } |
{ | ||
"name": "async-validator", | ||
"version": "1.5.0", | ||
"version": "1.5.1", | ||
"description": "validate form asynchronous", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
52834
1137