From 53411119a025505393c5dad52123793a18c58028 Mon Sep 17 00:00:00 2001 From: Sander Steffann Date: Sat, 23 Nov 2019 00:48:42 +0100 Subject: [PATCH] Fix the default value of `enabled` when not included in the import --- netbox/dcim/forms.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netbox/dcim/forms.py b/netbox/dcim/forms.py index 5fad96d0f..22ec2f3a4 100644 --- a/netbox/dcim/forms.py +++ b/netbox/dcim/forms.py @@ -2495,7 +2495,7 @@ class InterfaceCSVForm(forms.ModelForm): def clean_enabled(self): # Make sure enabled is True when it's not included in the uploaded data - if 'enabled' in self.data: + if 'enabled' not in self.data: return True else: return self.cleaned_data['enabled']