Ignore fields in CONSTANCE_ADDITIONAL_FIELDS when casting a type

This commit is contained in:
Camilo Nova 2016-10-12 16:59:56 -05:00
parent 4fc8fdd3d0
commit 2f88a1bff2

View file

@ -88,7 +88,7 @@ class ConstanceForm(forms.Form):
for name, options in settings.CONFIG.items():
default, help_text = options[0], options[1]
if len(options) == 3:
if len(options) == 3 and options[2] not in settings.ADDITIONAL_FIELDS:
config_type = options[2]
if not isinstance(options[0], config_type):
raise ImproperlyConfigured(_("Default value type must be "