From 6a15c2ae8611c4ed9b4fa14fdf7e41ba489887e2 Mon Sep 17 00:00:00 2001 From: thatmattlove Date: Tue, 7 Sep 2021 18:37:55 -0700 Subject: [PATCH] Remove invalid (for Python <3.9) type annotation --- netbox/utilities/forms/fields.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netbox/utilities/forms/fields.py b/netbox/utilities/forms/fields.py index 6684eb908..cf7bff14f 100644 --- a/netbox/utilities/forms/fields.py +++ b/netbox/utilities/forms/fields.py @@ -478,7 +478,7 @@ class DynamicModelMultipleChoiceField(DynamicModelChoiceMixin, forms.ModelMultip filter = django_filters.ModelMultipleChoiceFilter widget = widgets.APISelectMultiple - def clean(self, value: list[str]): + def clean(self, value): """ When null option is enabled and "None" is sent as part of a form to be submitted, it is sent as the string 'null'. This will check for that condition and gracefully handle the conversion to a NoneType.