diff --git a/src/util/twemojify.jsx b/src/util/twemojify.jsx
index 9bf86a184f..aed8b09d13 100644
--- a/src/util/twemojify.jsx
+++ b/src/util/twemojify.jsx
@@ -10,11 +10,12 @@ const Math = lazy(() => import('../app/atoms/math/Math'));
const mathOptions = {
replace: (node) => {
- if (node.attribs?.['data-mx-maths']) {
+ const maths = node.attribs?.['data-mx-maths'];
+ if (maths) {
return (
- }>
+ {maths}}>