mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-21 11:37:21 -06:00
Merge pull request #8063 from rizlas/develop
Get_Environment from napalm should not need any decoding
This commit is contained in:
commit
7569544b7b
@ -501,7 +501,7 @@ class DeviceViewSet(ConfigContextQuerySetMixin, CustomFieldModelViewSet):
|
|||||||
response[method] = {'error': 'Only get_* NAPALM methods are supported'}
|
response[method] = {'error': 'Only get_* NAPALM methods are supported'}
|
||||||
continue
|
continue
|
||||||
try:
|
try:
|
||||||
response[method] = decode_dict(getattr(d, method)())
|
response[method] = getattr(d, method)()
|
||||||
except NotImplementedError:
|
except NotImplementedError:
|
||||||
response[method] = {'error': 'Method {} not implemented for NAPALM driver {}'.format(method, driver)}
|
response[method] = {'error': 'Method {} not implemented for NAPALM driver {}'.format(method, driver)}
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
Loading…
Reference in New Issue
Block a user