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

contactmodel: remove pending requests for SIP

Change-Id: I04bb0e235d1d70da968993d44c845785fd02be46
parent a91dbc4d
No related branches found
No related tags found
No related merge requests found
...@@ -827,8 +827,11 @@ ContactModelPimpl::slotNewAccountMessage(std::string& accountId, ...@@ -827,8 +827,11 @@ ContactModelPimpl::slotNewAccountMessage(std::string& accountId,
if (contacts.find(from) == contacts.end()) { if (contacts.find(from) == contacts.end()) {
// Contact not found, load profile from database. // Contact not found, load profile from database.
// The conversation model will create an entry and link the incomingCall. // The conversation model will create an entry and link the incomingCall.
addToContacts(from, profile::Type::PENDING, false); auto type = (linked.owner.profileInfo.type == profile::Type::RING)
emitNewTrust = true; ? profile::Type::PENDING
: profile::Type::SIP;
addToContacts(from, type, false);
emitNewTrust = (linked.owner.profileInfo.type == profile::Type::RING);
} }
} }
if (emitNewTrust) { if (emitNewTrust) {
...@@ -848,8 +851,11 @@ ContactModelPimpl::slotNewAccountTransfer(long long dringId, datatransfer::Info ...@@ -848,8 +851,11 @@ ContactModelPimpl::slotNewAccountTransfer(long long dringId, datatransfer::Info
if (contacts.find(info.peerUri) == contacts.end()) { if (contacts.find(info.peerUri) == contacts.end()) {
// Contact not found, load profile from database. // Contact not found, load profile from database.
// The conversation model will create an entry and link the incomingCall. // The conversation model will create an entry and link the incomingCall.
addToContacts(info.peerUri, profile::Type::PENDING, false); auto type = (linked.owner.profileInfo.type == profile::Type::RING)
emitNewTrust = true; ? profile::Type::PENDING
: profile::Type::SIP;
addToContacts(info.peerUri, type, false);
emitNewTrust = (linked.owner.profileInfo.type == profile::Type::RING);
} }
} }
if (emitNewTrust) { if (emitNewTrust) {
......
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