Explorar o código

Fix SVG rendering with unspecified width

jeremystretch %!s(int64=4) %!d(string=hai) anos
pai
achega
443172197b
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      netbox/dcim/api/views.py

+ 1 - 1
netbox/dcim/api/views.py

@@ -54,7 +54,7 @@ class PathEndpointMixin(object):
             # Render SVG
             try:
                 width = min(int(request.GET.get('width')), 1600)
-            except ValueError:
+            except (ValueError, TypeError):
                 width = None
             drawing = obj.get_trace_svg(
                 base_url=request.build_absolute_uri('/'),