ansman/validate.js

Numericality validator fails on empty string

Opened this issue · 0 comments

aepp commented

var validate = require("validate.js")
var constraints = { amount: { numericality: true  } }
var form = { amount: '' }

console.log(validate(form, constraints)) // returns ["Amount is not a number"]

The original issue #224 is closed but the behavior is still the same in v0.12.0.