Merge pull request #245 from zmolodchenko/patch-1
fix error reporting, where choices is list of flat values
This commit is contained in:
commit
9f58bc9207
@ -252,7 +252,7 @@ class BaseField(object):
|
|||||||
elif value_to_check not in self.choices:
|
elif value_to_check not in self.choices:
|
||||||
msg = ('Value must be %s of %s' %
|
msg = ('Value must be %s of %s' %
|
||||||
(err_msg, unicode(self.choices)))
|
(err_msg, unicode(self.choices)))
|
||||||
self.error()
|
self.error(msg)
|
||||||
|
|
||||||
# check validation argument
|
# check validation argument
|
||||||
if self.validation is not None:
|
if self.validation is not None:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user