不要怂,就是干,撸起袖子干!

Commit eb064697 by Mick Hansen

Merge pull request #5429 from cbauerme/validator-fix

Added condition to arg passer for validators.
2 parents 5132e4d2 9a75a5db
Showing with 1 additions and 1 deletions
......@@ -261,7 +261,7 @@ InstanceValidator.prototype._invokeBuiltinValidator = Promise.method(function(va
if (!Array.isArray(validatorArgs)) {
if (validatorType === 'isImmutable') {
validatorArgs = [validatorArgs, field];
} else if (validatorType === 'isIP') {
} else if (validatorType === 'isIP' || validatorType === 'isAlpha' || validatorType === 'isAlphanumeric') {
validatorArgs = [];
} else {
validatorArgs = [validatorArgs];
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!