Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #43 from lgomezma/master

Fix present validation check
  • Loading branch information...
commit 199f82b797db514dd13cd29297cbc80061083162 2 parents 8db4514 + f24e509
@mde mde authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/validators.js
View
2  lib/validators.js
@@ -33,7 +33,7 @@ var utils = require('utilities')
var validators = {
present: function (name, val, params, rule, locale) {
var msg;
- if (!val) {
+ if (typeof val === "undefined" || val=="") {
//'Field "' + name + '" is required.';
msg = rule.message || i18n.getText('model.validatesPresent',
{name: name}, locale);
Please sign in to comment.
Something went wrong with that request. Please try again.