core; fix variable being shadowed

This commit is contained in:
Jens Langhammer 2018-12-10 15:42:13 +01:00
parent bba10c6db4
commit 85a2280eaf
1 changed files with 1 additions and 1 deletions

View File

@ -52,7 +52,7 @@ class SignUpForm(forms.Form):
super().__init__(*args, **kwargs) super().__init__(*args, **kwargs)
# All fields which have initial data supplied are set to read only # All fields which have initial data supplied are set to read only
if 'initial' in kwargs: 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' self.fields[field].widget.attrs['readonly'] = 'readonly'
# TODO: Dynamically add captcha here # TODO: Dynamically add captcha here
# if not Setting.get_bool('recaptcha:enabled'): # if not Setting.get_bool('recaptcha:enabled'):