From 21f54486b20e8413153e53d00fa5cab3132307c9 Mon Sep 17 00:00:00 2001 From: Hugo LEVY-FALK Date: Tue, 1 Jan 2019 20:17:27 +0100 Subject: [PATCH] Fix switch creation --- topologie/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/topologie/models.py b/topologie/models.py index 269516ff..e08a1b21 100644 --- a/topologie/models.py +++ b/topologie/models.py @@ -304,7 +304,7 @@ class Switch(AclMixin, Machine): @cached_property def get_name(self): - return self.name or self.main_interface().domain.name + return self.name or getattr(self.main_interface(), 'domain', 'Unknown') @cached_property def get_radius_key(self):