diff options
author | userimack <mahendra.k12@gmail.com> | 2016-01-23 22:17:07 +0530 |
---|---|---|
committer | Tim Graham <timograham@gmail.com> | 2016-01-25 14:23:43 -0500 |
commit | 60586dd7379b295b72d8af4e03423c286913b5e8 (patch) | |
tree | 6f834957ea76305fbcda40e23e836077890d36b8 /django/contrib/postgres/validators.py | |
parent | abc0777b63057e2ff97eee2ff184356051e14c47 (diff) | |
download | django-60586dd7379b295b72d8af4e03423c286913b5e8.tar.gz |
Fixed #26125 -- Fixed E731 flake warnings.
Diffstat (limited to 'django/contrib/postgres/validators.py')
-rw-r--r-- | django/contrib/postgres/validators.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/django/contrib/postgres/validators.py b/django/contrib/postgres/validators.py index 3f576873f4..69ceeea8ba 100644 --- a/django/contrib/postgres/validators.py +++ b/django/contrib/postgres/validators.py @@ -69,10 +69,12 @@ class KeysValidator(object): class RangeMaxValueValidator(MaxValueValidator): - compare = lambda self, a, b: a.upper > b + def compare(self, a, b): + return a.upper > b message = _('Ensure that this range is completely less than or equal to %(limit_value)s.') class RangeMinValueValidator(MinValueValidator): - compare = lambda self, a, b: a.lower < b + def compare(self, a, b): + return a.lower < b message = _('Ensure that this range is completely greater than or equal to %(limit_value)s.') |