diff options
| author | Tim Graham <timograham@gmail.com> | 2018-08-01 11:48:21 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2018-08-01 11:52:02 -0400 |
| commit | 4263cd0e095c55a1011e5bf0746d651126a8da5f (patch) | |
| tree | 3d26e8110fdac6b80b96bd317072f8d6021bc814 | |
| parent | 25dd595742dd1d24c19421c25fe261036b3d0f8b (diff) | |
Simplified comment in BooleanField.to_python().
| -rw-r--r-- | django/db/models/fields/__init__.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/django/db/models/fields/__init__.py b/django/db/models/fields/__init__.py index 50d22bef0c..dbadfc6c90 100644 --- a/django/db/models/fields/__init__.py +++ b/django/db/models/fields/__init__.py @@ -998,8 +998,7 @@ class BooleanField(Field): if self.null and value in self.empty_values: return None if value in (True, False): - # if value is 1 or 0 than it's equal to True or False, but we want - # to return a true bool for semantic reasons. + # 1/0 are equal to True/False. bool() converts former to latter. return bool(value) if value in ('t', 'True', '1'): return True |
