Parcourir la source

Handle split paths

Jeremy Stretch il y a 5 ans
Parent
commit
75ddc63466
1 fichiers modifiés avec 3 ajouts et 0 suppressions
  1. 3 0
      netbox/dcim/api/views.py

+ 3 - 0
netbox/dcim/api/views.py

@@ -58,6 +58,9 @@ class PathEndpointMixin(object):
         path = []
 
         for near_end, cable, far_end in obj.trace():
+            if near_end is None:
+                # Split paths
+                break
 
             # Serialize each object
             serializer_a = get_serializer_for_model(near_end, prefix='Nested')