Revert "be case insensitive on value choices (closes #1319)"

This reverts commit ebb87844f3.
This commit is contained in:
Florent 2014-09-02 12:46:04 +02:00
commit 8a25c75999

View file

@ -89,7 +89,7 @@ class Value(object):
raise ValueError('Value can\'t be empty')
if self.regexp is not None and not re.match(self.regexp, unicode(v)):
raise ValueError('Value "%s" does not match regexp "%s"' % (v, self.regexp))
if self.choices is not None and not v.lower() in map(str.lower, self.choices.iterkeys()):
if self.choices is not None and not v in self.choices.iterkeys():
raise ValueError('Value "%s" is not in list: %s' % (
v, ', '.join(unicode(s) for s in self.choices.iterkeys())))