summaryrefslogtreecommitdiff
path: root/src/xhtml.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/xhtml.py')
-rw-r--r--src/xhtml.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/xhtml.py b/src/xhtml.py
index 1c9c20e7..ce53029e 100644
--- a/src/xhtml.py
+++ b/src/xhtml.py
@@ -193,6 +193,8 @@ def get_body_from_message_stanza(message):
if config.get('enable_xhtml_im', 'true') == 'true':
xhtml_body = message['html']['body']
if xhtml_body:
+ if isinstance(xhtml_body, str):
+ xhtml_body = ET.fromstring(xhtml_body)
content = xhtml_to_poezio_colors(xhtml_body)
content = content if content else message['body']
return content or " "