summaryrefslogtreecommitdiff
path: root/django/forms
diff options
context:
space:
mode:
Diffstat (limited to 'django/forms')
-rw-r--r--django/forms/widgets.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/django/forms/widgets.py b/django/forms/widgets.py
index c761ea857d..4782b99117 100644
--- a/django/forms/widgets.py
+++ b/django/forms/widgets.py
@@ -533,6 +533,9 @@ class CheckboxInput(Widget):
def _has_changed(self, initial, data):
# Sometimes data or initial could be None or '' which should be the
# same thing as False.
+ if initial == 'False':
+ # show_hidden_initial may have transformed False to 'False'
+ initial = False
return bool(initial) != bool(data)
class Select(Widget):