Corrected parsing of _house_arrest_get_result()

This commit is contained in:
GRiker 2013-06-11 14:38:44 -06:00
parent cc3b349705
commit 40eacd40da

View File

@ -1174,10 +1174,10 @@ class libiMobileDevice():
self.plist_lib.plist_free(plist) self.plist_lib.plist_free(plist)
# To determine success, we need to inspect the returned plist # To determine success, we need to inspect the returned plist
if hasattr(result, 'Status'): if 'Status' in result:
if self.verbose: if self.verbose:
self.log(" STATUS: %s" % result['Status']) self.log(" STATUS: %s" % result['Status'])
elif hasattr(result, 'Error'): elif 'Error' in result:
if self.verbose: if self.verbose:
self.log(" ERROR: %s" % result['Error']) self.log(" ERROR: %s" % result['Error'])
raise libiMobileDeviceException(result['Error']) raise libiMobileDeviceException(result['Error'])