Skip to content

Commit

Permalink
Merge pull request #14 from djedi-knight/master
Browse files Browse the repository at this point in the history
Added string validation to StringField
  • Loading branch information
bogus34 committed Nov 13, 2017
2 parents e855349 + c5d38a1 commit 45e2da0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/fields.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ class StringField extends Field
result = super
@acceptsRule result, ['minLength', 'min_length']
@acceptsRule result, ['maxLength', 'max_length']
result.unshift @_withMessage 'string'
result

class EmailField extends StringField
Expand Down

0 comments on commit 45e2da0

Please sign in to comment.