Random fixes (#1996)
* OwnTracks handle malformed data better Fixes #1991 . * Remove dependency for util.dt
This commit is contained in:
1 parent
8a16a7d943
commit
6901e5ea5e
2 files changed
+3
-4
No files matched your search
@@ -101,7 +101,7 @@ def setup_scanner(hass, config, see):
|
||||
"""Execute enter event."""
|
||||
zone = hass.states.get("zone.{}".format(location))
|
||||
with LOCK:
|
||||
if zone is None and data['t'] == 'b':
|
||||
if zone is None and data.get('t') == 'b':
|
||||
# Not a HA zone, and a beacon so assume mobile
|
||||
beacons = MOBILE_BEACONS_ACTIVE[dev_id]
|
||||
if location not in beacons:
|
||||
|
||||
Reference in new issue
Block a user