This commit is contained in:
Jack Robison 2018-07-28 23:25:13 -04:00
parent 7c26e7e6a7
commit 94a65e5d8f
No known key found for this signature in database
GPG key ID: DF25C68FE0239BB2

View file

@ -54,11 +54,12 @@ class RootDevice(object):
log.exception("failed to decode xml")
log.error(xml_string)
log.info(binascii.hexlify(xml_string))
return
root = {}
self.spec_version = root.get(SPEC_VERSION)
self.url_base = root["URLBase"]
self.url_base = root.get("URLBase")
self.devices = []
self.services = []
if root:
root_device = Device(self, **(root["device"]))
self.devices.append(root_device)
log.info("finished setting up root device. %i devices and %i services", len(self.devices), len(self.services))