mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-23 06:08:07 +00:00
Moved code that fill the contentsList of ChatMessage from MultipartChatModifier to ChatMessage itself
This commit is contained in:
parent
df8aedecc3
commit
32e22abee2
2 changed files with 5 additions and 3 deletions
|
|
@ -996,6 +996,11 @@ LinphoneReason ChatMessagePrivate::receive() {
|
|||
MultipartChatMessageModifier mcmm;
|
||||
mcmm.decode(q->getSharedFromThis(), &errorCode);
|
||||
|
||||
if (contents.size() == 0) {
|
||||
// All previous modifiers only altered the internal content, let's fill the content list
|
||||
contents.push_back(internalContent);
|
||||
}
|
||||
|
||||
// ---------------------------------------
|
||||
// End of message modification
|
||||
// ---------------------------------------
|
||||
|
|
|
|||
|
|
@ -40,9 +40,6 @@ ChatMessageModifier::Result MultipartChatMessageModifier::decode (shared_ptr<Cha
|
|||
if (false) { // Multipart required
|
||||
|
||||
return ChatMessageModifier::Result::Done;
|
||||
} else if (message->getContents().size() == 0) {
|
||||
// All previous modifiers only altered the internal content, let's fill the content list because we're the last modifier to be called
|
||||
message->addContent(message->getInternalContent());
|
||||
}
|
||||
return ChatMessageModifier::Result::Skipped;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue