Philipp Hörist pushed to branch master at gajim / gajim


Commits:
59bee7d7 by Philipp Hörist at 2024-06-29T10:21:14+02:00
fix: Remove unnecessary space between quotes

Fixes #11886

- - - - -


1 changed file:

- gajim/gtk/conversation/plain_widget.py


Changes:

=====================================
gajim/gtk/conversation/plain_widget.py
=====================================
@@ -100,7 +100,6 @@ def _build_link_markup(self, text: str, uris: 
list[BaseHyperlink]) -> str:
     def print_text_with_styling(self, block: PlainBlock) -> None:
         text = self._build_link_markup(block.text, block.uris)
         self.set_markup(text)
-
         if len(self.get_text()) > MAX_MESSAGE_LENGTH:
             # Limit message styling processing
             return
@@ -108,7 +107,9 @@ def print_text_with_styling(self, block: PlainBlock) -> 
None:
         self.set_attributes(make_pango_attributes(block))
 
         stripped = text.strip()
-        if emoji.purely_emoji(stripped):
+        # https://github.com/carpedm20/emoji/issues/300
+        # purely_emoji() return True for the empty string
+        if stripped and emoji.purely_emoji(stripped):
             emoji_count = emoji.emoji_count(stripped)
             if emoji_count == 1:
                 classname = 'gajim-single-emoji-msg'



View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/59bee7d706996b3bc8d6c0eb65ed0f057b1c460b

-- 
View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/59bee7d706996b3bc8d6c0eb65ed0f057b1c460b
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