From be02f67eeffb2238e4434ffb081c7739090c9e3b Mon Sep 17 00:00:00 2001 From: Andrew Morgan Date: Thu, 11 Apr 2019 00:09:38 +0100 Subject: [PATCH] Switch logic --- src/HtmlUtils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/HtmlUtils.js b/src/HtmlUtils.js index f85fc9bc5e..bde3978677 100644 --- a/src/HtmlUtils.js +++ b/src/HtmlUtils.js @@ -519,7 +519,7 @@ export function bodyToHtml(content, highlights, opts={}) { emojiBody = match && match[0] && match[0].length === contentBodyTrimmed.length // Prevent user pills expanding for users with only emoji in // their username - && (content.formatted_body && !content.formatted_body.includes("https://matrix.to/")); + && (!content.formatted_body || !content.formatted_body.includes("https://matrix.to/")); } const className = classNames({