Daniel Brötzmann pushed to branch master at gajim / gajim


Commits:
36e96a3d by wurstsalat at 2025-03-13T23:07:20+01:00
fix: AdHoc: Don't fail if dataform widget is not set when cancelling

Fixes #12227

- - - - -


1 changed file:

- gajim/gtk/adhoc.py


Changes:

=====================================
gajim/gtk/adhoc.py
=====================================
@@ -280,10 +280,15 @@ def __init__(self) -> None:
         self.default = None
 
     @property
-    def stage_data(self) -> tuple[AdHocCommand, SimpleDataForm | 
MultipleDataForm]:
+    def stage_data(
+        self,
+    ) -> tuple[AdHocCommand, SimpleDataForm | MultipleDataForm | None]:
         assert self._last_stage_data is not None
+        form = None
+        if self._dataform_widget is not None:
+            form = self._dataform_widget.get_submit_form()
         assert self._dataform_widget is not None
-        return self._last_stage_data, self._dataform_widget.get_submit_form()
+        return self._last_stage_data, form
 
     @property
     def actions(self) -> set[AdHocAction] | None:



View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/36e96a3dc47976bd3d435c9025511d132e40f611

-- 
View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/36e96a3dc47976bd3d435c9025511d132e40f611
You're receiving this email because of your account on dev.gajim.org.


_______________________________________________
Commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to