diff options
Diffstat (limited to 'scripts/status_script.py')
-rwxr-xr-x | scripts/status_script.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/status_script.py b/scripts/status_script.py index 29a1e97..a92d5bf 100755 --- a/scripts/status_script.py +++ b/scripts/status_script.py @@ -17,7 +17,11 @@ class SublabStatus(object): return self.json def door_status(self): - self.get_json() + try: + self.get_json() + except Exception: + return 'unkown' + door_status = self.json['door.lock'] if door_status['ts'] + 120 < time.time(): |