mirror of
https://github.com/liberatedsystems/Sideband_CE.git
synced 2024-09-03 04:13:27 +02:00
Fixed missing check for none value
This commit is contained in:
parent
c39b7ac148
commit
6120c1dd31
@ -814,7 +814,7 @@ class Location(Sensor):
|
|||||||
if slat != None and slon != None:
|
if slat != None and slon != None:
|
||||||
s = relative_to.sensors["location"]
|
s = relative_to.sensors["location"]
|
||||||
d = s.data
|
d = s.data
|
||||||
if "latitude" in d and "longitude" in d and "altitude" in d:
|
if d != None and "latitude" in d and "longitude" in d and "altitude" in d:
|
||||||
lat = d["latitude"]; lon = d["longitude"]; alt = d["altitude"]
|
lat = d["latitude"]; lon = d["longitude"]; alt = d["altitude"]
|
||||||
if lat != None and lon != None:
|
if lat != None and lon != None:
|
||||||
if alt == None: alt = 0
|
if alt == None: alt = 0
|
||||||
|
Loading…
Reference in New Issue
Block a user