From 7f77a3dd6b394d7145bbcb946afd95fcb80c4330 Mon Sep 17 00:00:00 2001 From: Sjur Fredriksen Date: Sun, 16 Feb 2025 20:45:54 +0100 Subject: unneeded validation check, regex ensures input is valid --- tools/netbox/scripts/create-switch/create-switch-tg25.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/tools/netbox/scripts/create-switch/create-switch-tg25.py b/tools/netbox/scripts/create-switch/create-switch-tg25.py index 0703b3d..f932bf4 100644 --- a/tools/netbox/scripts/create-switch/create-switch-tg25.py +++ b/tools/netbox/scripts/create-switch/create-switch-tg25.py @@ -140,9 +140,6 @@ class CreateSwitch(Script): ) def run(self, data, commit): - if not data['switch_name'].startswith("e") and not data['switch_name'].startswith("d"): - raise ValidationError("Switch name must start whit e or d") - switch = self.create_switch(data) vlan = self.create_vlan(switch) -- cgit v1.2.3