GUI: another fix for not init repos

This commit is contained in:
deajan 2024-04-23 22:34:07 +02:00
parent 67adf6e0ef
commit c898849632

View file

@ -228,7 +228,7 @@ def ls_window(repo_config: dict, snapshot_id: str) -> bool:
__autoclose=True,
__compact=True,
)
if not result["result"]:
if not result or not result["result"]:
sg.Popup("main_gui.snapshot_is_empty")
return None, None
# result is {"result": True, "output": [{snapshot_description}, {entry}, {entry}]}
@ -492,7 +492,7 @@ def _main_gui(viewer_mode: bool):
__autoclose=True,
__compact=True,
)
if not result["result"]:
if not result or not result["result"]:
snapshots = None
else:
snapshots = result["output"]