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

invitationview: sort per received timestamp

We sort the invites by last interactions. However on swarm, there
is no interaction yet. Add one with the received timestamp given
by the daemon.
(Regression appears because we were showing trust request before
not conversation requests)

Change-Id: Ic7f4d1a5d485325c95a19c2c38ae9c74630829ce
GitLab: #956
parent 1a4fffff
No related branches found
No related tags found
No related merge requests found
......@@ -3063,6 +3063,17 @@ ConversationModelPimpl::addConversationRequest(const MapStringString& convReques
conversation.mode = mode;
conversation.isRequest = true;
MapStringString messageMap = {
{"type", "initial"},
{"author", peerUri},
{"timestamp", convRequest["received"]},
{"linearizedParent", ""},
};
auto msg = interaction::Info(messageMap, linked.owner.profileInfo.uri);
insertSwarmInteraction(convId, msg, conversation, true);
conversation.lastMessageUid = convId;
// add the author to the contact model's contact list as a PENDING
// if they aren't already a contact
auto isSelf = linked.owner.profileInfo.uri == peerUri;
......
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