From f1f8d82f5246b462c01744a9d0a214a259c5bd20 Mon Sep 17 00:00:00 2001 From: jschindehette Date: Tue, 12 Dec 2017 12:24:07 -0500 Subject: [PATCH] Fixed functionality of simple sequences in struct properties for devices --- rest/helper.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/rest/helper.py b/rest/helper.py index ecc912e..1da33ec 100644 --- a/rest/helper.py +++ b/rest/helper.py @@ -112,8 +112,10 @@ def _handle_struct(prop): p_dict.pop('type', None) p_dict['value'] = [] for _, m in prop.members.iteritems(): - m_dict = _handle_simple(m) - p_dict['value'].append( m_dict ) + if type(m) == sequenceProperty: + p_dict['value'].append( _handle_simpleseq(m) ) + else: + p_dict['value'].append( _handle_simple(m) ) p_dict['scaType'] = 'struct' return p_dict