Skip to content

Commit

Permalink
fix(main): check if a session timer was creating before cancelling it
Browse files Browse the repository at this point in the history
Signed-off-by: Cedric Hombourger <[email protected]>
  • Loading branch information
chombourger committed Jan 6, 2025
1 parent a63f663 commit 523e9b2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mtda/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ def __init__(self):
self._pastebin_api_key = None
self._pastebin_endpoint = None
self._session_manager = None
self._session_timer = None
self._storage_locked = False
self._storage_mounted = False
self._storage_opened = False
Expand Down Expand Up @@ -1646,7 +1647,8 @@ def stop(self):
return True

# stop sesssion timer
self._session_timer.cancel()
if self._session_timer:
self._session_timer.cancel()

# stop web service
if self._www is not None:
Expand Down

0 comments on commit 523e9b2

Please sign in to comment.