From a96deb7bc002b33bc5301af8aa9af4d7c131db94 Mon Sep 17 00:00:00 2001 From: Anthony Bilinski Date: Sun, 6 Mar 2022 00:13:42 -0800 Subject: [PATCH] refactor(settings): Remove unused Settings::getFriendAddress --- src/persistence/settings.cpp | 11 ----------- src/persistence/settings.h | 1 - 2 files changed, 12 deletions(-) diff --git a/src/persistence/settings.cpp b/src/persistence/settings.cpp index 4e7b817ba..b177353c1 100644 --- a/src/persistence/settings.cpp +++ b/src/persistence/settings.cpp @@ -1909,17 +1909,6 @@ void Settings::setCamVideoFPS(float newValue) } } -QString Settings::getFriendAddress(const QString& publicKey) const -{ - QMutexLocker locker{&bigLock}; - QByteArray key = ToxPk(publicKey).getByteArray(); - auto it = friendLst.find(key); - if (it != friendLst.end()) - return it->addr; - - return QString(); -} - void Settings::updateFriendAddress(const QString& newAddr) { QMutexLocker locker{&bigLock}; diff --git a/src/persistence/settings.h b/src/persistence/settings.h index 1c69b3b4a..10190980a 100644 --- a/src/persistence/settings.h +++ b/src/persistence/settings.h @@ -488,7 +488,6 @@ public: QByteArray getDialogSettingsGeometry() const; void setDialogSettingsGeometry(const QByteArray& value); - QString getFriendAddress(const QString& publicKey) const; void updateFriendAddress(const QString& newAddr); QString getFriendAlias(const ToxPk& id) const override;