m-validate
Advanced tools
Comparing version 2.1.2 to 2.2.0
@@ -61,6 +61,15 @@ var Localization = require('i18n-2'); | ||
if (splitedResponse.length > 1) { | ||
(response[fieldName])[rule] = this.i18n.__( | ||
splitedResponse[0] + ': %d', | ||
parseInt(splitedResponse[1], 10) | ||
var res = this.i18n.__n( | ||
splitedResponse[0] + ': %f', | ||
Number(splitedResponse[1]) | ||
); | ||
if (!res) { | ||
res = this.i18n.__( | ||
splitedResponse[0] + ': %f', | ||
Number(splitedResponse[1]) | ||
); | ||
} | ||
(response[fieldName])[rule] = res; | ||
} else { | ||
@@ -67,0 +76,0 @@ (response[fieldName])[rule] = this.i18n |
{ | ||
"name": "m-validate", | ||
"version": "2.1.2", | ||
"version": "2.2.0", | ||
"description": "NodeJS simple validation functions", | ||
@@ -5,0 +5,0 @@ "main": "m-validate.js", |
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
22645
288