status: the device may be invalid when processing the unpair notification

This commit is contained in:
Daniel Pavel 2013-06-21 16:39:30 +02:00
parent 8d522de7e7
commit 5785896007
1 changed files with 1 additions and 1 deletions

View File

@ -218,7 +218,7 @@ class DeviceStatus(dict):
def _changed(self, active=None, alert=ALERT.NONE, reason=None, timestamp=None):
assert self._changed_callback
d = self._device
assert d
# assert d # may be invalid when processing the 'unpaired' notification
if active is not None:
d.online = active