fix: Only add a <body> element when specified

This commit is contained in:
PapaTutuWawa 2022-12-09 12:52:00 +01:00
parent cc1b371198
commit 88efdc361c

View File

@ -186,9 +186,11 @@ class MessageManager extends XmppManagerBase {
body = details.messageRetraction!.fallback; body = details.messageRetraction!.fallback;
} }
stanza.addChild( if (body != null) {
XMLNode(tag: 'body', text: body), stanza.addChild(
); XMLNode(tag: 'body', text: body),
);
}
} }
if (details.requestDeliveryReceipt) { if (details.requestDeliveryReceipt) {