Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim-plugins.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--acronyms_expander/acronyms_expander.py5
-rw-r--r--acronyms_expander/plugin-manifest.json2
2 files changed, 5 insertions, 2 deletions
diff --git a/acronyms_expander/acronyms_expander.py b/acronyms_expander/acronyms_expander.py
index 49e974a..bd27934 100644
--- a/acronyms_expander/acronyms_expander.py
+++ b/acronyms_expander/acronyms_expander.py
@@ -99,6 +99,10 @@ class AcronymsExpanderPlugin(GajimPlugin):
buffer_: Gtk.TextBuffer
) -> None:
+ if self._contact is None:
+ # If no chat has been activated yet
+ return
+
if self._replace_in_progress:
return
@@ -132,7 +136,6 @@ class AcronymsExpanderPlugin(GajimPlugin):
# Get last word and cut invoker
last_word = word_start_iter.get_slice(insert_iter)
- assert self._contact is not None
if isinstance(self._contact, GroupchatContact):
if last_word in self._contact.get_user_nicknames():
log.info('Groupchat participant has same nick as acronym')
diff --git a/acronyms_expander/plugin-manifest.json b/acronyms_expander/plugin-manifest.json
index 7ef627e..31d1d70 100644
--- a/acronyms_expander/plugin-manifest.json
+++ b/acronyms_expander/plugin-manifest.json
@@ -17,5 +17,5 @@
"gajim>=1.5.0"
],
"short_name": "acronyms_expander",
- "version": "1.4.6"
+ "version": "1.4.7"
} \ No newline at end of file