From: Thierry Parmentelat Date: Tue, 15 Nov 2011 13:40:47 +0000 (+0100) Subject: cosmetic X-Git-Tag: sfa-1.1-3~19 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=f587945d567f05ea2e49b224653d0bdf8825a02e;p=sfa.git cosmetic --- diff --git a/sfa/rspecs/elements/element.py b/sfa/rspecs/elements/element.py index a841323c..6f15d601 100644 --- a/sfa/rspecs/elements/element.py +++ b/sfa/rspecs/elements/element.py @@ -34,6 +34,7 @@ class Element(dict): if field in elem.attrib: obj[field] = elem.attrib[field] objs.append(obj) +# xxx seems unused generic_elems = [element_class(elem.attrib, elem) for elem in elems] return objs diff --git a/sfa/rspecs/elements/versions/sfav1Node.py b/sfa/rspecs/elements/versions/sfav1Node.py index c2f1907a..838ae124 100644 --- a/sfa/rspecs/elements/versions/sfav1Node.py +++ b/sfa/rspecs/elements/versions/sfav1Node.py @@ -50,8 +50,10 @@ class SFAv1Node: if 'authority_id' in node and node['authority_id']: node_elem.set('site_id', node['authority_id']) - location_elems = Element.add_elements(node_elem, 'location', node.get('location', []), Location.fields) - interface_elems = Element.add_elements(node_elem, 'interface', node.get('interfaces', []), Interface.fields) + location_elems = Element.add_elements(node_elem, 'location', + node.get('location', []), Location.fields) + interface_elems = Element.add_elements(node_elem, 'interface', + node.get('interfaces', []), Interface.fields) #if 'bw_unallocated' in node and node['bw_unallocated']: # bw_unallocated = etree.SubElement(node_elem, 'bw_unallocated', units='kbps').text = str(int(node['bw_unallocated'])/1000)