summaryrefslogtreecommitdiff
path: root/django/core/validators.py
diff options
context:
space:
mode:
authorAnton Samarchyan <anton.samarchyan@savoirfairelinux.com>2017-01-25 14:02:33 -0500
committerTim Graham <timograham@gmail.com>2017-02-21 11:58:42 -0500
commit5a6f70b4281817656db2f36c5919036d38fcce7f (patch)
tree0fa649e905d960b54c5a65d80be23e42f900c23d /django/core/validators.py
parent3eb679a86956d9eedf24492f0002de002f7180f5 (diff)
downloaddjango-5a6f70b4281817656db2f36c5919036d38fcce7f.tar.gz
Refs #27656 -- Updated django.core docstring verbs according to PEP 257.
Diffstat (limited to 'django/core/validators.py')
-rw-r--r--django/core/validators.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/django/core/validators.py b/django/core/validators.py
index 44db6c00f0..f55918c8ba 100644
--- a/django/core/validators.py
+++ b/django/core/validators.py
@@ -52,8 +52,8 @@ class RegexValidator:
def __call__(self, value):
"""
- Validates that the input matches the regular expression
- if inverse_match is False, otherwise raises ValidationError.
+ Validate that the input matches the regular expression
+ if inverse_match is False, otherwise raise ValidationError.
"""
if not (self.inverse_match is not bool(self.regex.search(
force_text(value)))):
@@ -280,10 +280,8 @@ ip_address_validator_map = {
def ip_address_validators(protocol, unpack_ipv4):
"""
- Depending on the given parameters returns the appropriate validators for
+ Depending on the given parameters, return the appropriate validators for
the GenericIPAddressField.
-
- This code is here, because it is exactly the same for the model and the form field.
"""
if protocol != 'both' and unpack_ipv4:
raise ValueError(