From 85a2280eaf4ac3d90c2a9b3f17dd47e1081d66f2 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Mon, 10 Dec 2018 15:42:13 +0100 Subject: [PATCH] core; fix variable being shadowed --- passbook/core/forms/authentication.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passbook/core/forms/authentication.py b/passbook/core/forms/authentication.py index 658e97b05..8b409928a 100644 --- a/passbook/core/forms/authentication.py +++ b/passbook/core/forms/authentication.py @@ -52,7 +52,7 @@ class SignUpForm(forms.Form): super().__init__(*args, **kwargs) # All fields which have initial data supplied are set to read only if 'initial' in kwargs: - for field, _ in kwargs.get('initial').items(): + for field in kwargs.get('initial').keys(): self.fields[field].widget.attrs['readonly'] = 'readonly' # TODO: Dynamically add captcha here # if not Setting.get_bool('recaptcha:enabled'):