Skip to content

Commit

Permalink
Merge pull request MongoEngine#245 from zmolodchenko/patch-1
Browse files Browse the repository at this point in the history
fix error reporting, where choices is list of flat values
  • Loading branch information
rozza committed Mar 12, 2013
2 parents eeb672f + d36f6e7 commit 9f58bc9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mongoengine/base.py
Expand Up @@ -252,7 +252,7 @@ def _validate(self, value):
elif value_to_check not in self.choices:
msg = ('Value must be %s of %s' %
(err_msg, unicode(self.choices)))
self.error()
self.error(msg)

# check validation argument
if self.validation is not None:
Expand Down

0 comments on commit 9f58bc9

Please sign in to comment.