diff options
author | wurstsalat <mailtrash@posteo.de> | 2023-06-08 20:22:08 +0300 |
---|---|---|
committer | wurstsalat <mailtrash@posteo.de> | 2023-06-08 20:22:13 +0300 |
commit | dfe0cd605211097f4ae07f2667e661137028112b (patch) | |
tree | 810e7c52fa2f629b7de39d1f69f5288357e7e05f | |
parent | 47ab5462736059d45ee50a194854a54d2aa380c1 (diff) |
fix: Preview: Show error if file saving directory is not available
Fixes #11558
-rw-r--r-- | gajim/gtk/main.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gajim/gtk/main.py b/gajim/gtk/main.py index 8d0095281..415d59232 100644 --- a/gajim/gtk/main.py +++ b/gajim/gtk/main.py @@ -531,6 +531,13 @@ class MainWindow(Gtk.ApplicationWindow, EventHelper): elif action_name == 'preview-save-as': def _on_ok(paths: list[str]) -> None: + if not paths: + ErrorDialog( + _('Could not save file'), + _('Could not save file to selected directory.'), + transient_for=self) + return + target = paths[0] assert preview is not None assert preview.orig_path is not None |