summaryrefslogtreecommitdiff
path: root/protocols/Tox/src/tox_events.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Tox/src/tox_events.cpp')
-rw-r--r--protocols/Tox/src/tox_events.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/protocols/Tox/src/tox_events.cpp b/protocols/Tox/src/tox_events.cpp
index e372b9ee39..87c688c593 100644
--- a/protocols/Tox/src/tox_events.cpp
+++ b/protocols/Tox/src/tox_events.cpp
@@ -7,10 +7,9 @@ int CToxProto::OnContactDeleted(MCONTACT hContact, LPARAM)
return 1;
}
- ToxBinAddress pubKey = ptrA(getStringA(hContact, TOX_SETTINGS_ID));
if (!isChatRoom(hContact))
{
- int32_t friendNumber = tox_get_friend_number(tox, pubKey);
+ int32_t friendNumber = GetToxFriendNumber(hContact);
if (friendNumber == TOX_ERROR || tox_del_friend(tox, friendNumber) == TOX_ERROR)
{
return 1;