Skip to content
Snippets Groups Projects
Commit 3bdc0b52 authored by Sébastien Blin's avatar Sébastien Blin
Browse files

conversationmodel: fix reloading for merge commits

if the cache is cleaned but not the latest interaction, when
reloading, if the lastMessageUid is a merge commit, it will
not reload until the latest interaction

jami-client-qt#340

Change-Id: I91ade5b2e80957bb97fe711e95f2837330553b0e
parent 2b564384
No related branches found
No related tags found
No related merge requests found
...@@ -1392,8 +1392,9 @@ ConversationModel::clearInteractionsCache(const QString& convId) ...@@ -1392,8 +1392,9 @@ ConversationModel::clearInteractionsCache(const QString& convId)
std::lock_guard<std::mutex> lk(pimpl_->interactionsLocks[convId]); std::lock_guard<std::mutex> lk(pimpl_->interactionsLocks[convId]);
conversation.interactions->clear(); conversation.interactions->clear();
} }
ConfigurationManager::instance().loadConversationMessages(owner.id, convId, "", 1);
conversation.allMessagesLoaded = false; conversation.allMessagesLoaded = false;
conversation.lastMessageUid = "";
ConfigurationManager::instance().loadConversationMessages(owner.id, convId, "", 1);
} }
} catch (const std::out_of_range& e) { } catch (const std::out_of_range& e) {
qDebug() << "can't find interaction from conversation: " << e.what(); qDebug() << "can't find interaction from conversation: " << e.what();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment