From d15248f45b71f84780a2a74c8f59c7e6647b06a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Blin?= <sebastien.blin@savoirfairelinux.com> Date: Fri, 15 Jul 2022 16:17:25 -0400 Subject: [PATCH] configurationManager: remove unused API Change-Id: Ib415e149509e57979f76627ac3bb7c05d8254278 --- bin/jni/configurationmanager.i | 1 - src/client/configurationmanager.cpp | 7 ------- src/jami/configurationmanager_interface.h | 5 ----- src/jamidht/jamiaccount.cpp | 9 --------- src/jamidht/jamiaccount.h | 7 ------- 5 files changed, 29 deletions(-) diff --git a/bin/jni/configurationmanager.i b/bin/jni/configurationmanager.i index 73170ba64f..047a035dd5 100644 --- a/bin/jni/configurationmanager.i +++ b/bin/jni/configurationmanager.i @@ -220,7 +220,6 @@ std::map<std::string, std::string> getContactDetails(const std::string& accountI void connectivityChanged(); -void enableProxyClient(const std::string& accountID, bool enable); void setPushNotificationToken(const std::string& pushDeviceToken); void pushNotificationReceived(const std::string& from, const std::map<std::string, std::string>& data); diff --git a/src/client/configurationmanager.cpp b/src/client/configurationmanager.cpp index bd9689961e..4e28fa8512 100644 --- a/src/client/configurationmanager.cpp +++ b/src/client/configurationmanager.cpp @@ -1013,13 +1013,6 @@ registerName(const std::string& account, const std::string& password, const std: return false; } -void -enableProxyClient(const std::string& accountID, bool enable) -{ - if (auto account = jami::Manager::instance().getAccount<jami::JamiAccount>(accountID)) - account->enableProxyClient(enable); -} - void setPushNotificationToken(const std::string& token) { diff --git a/src/jami/configurationmanager_interface.h b/src/jami/configurationmanager_interface.h index 44731f67b6..b5ada18e37 100644 --- a/src/jami/configurationmanager_interface.h +++ b/src/jami/configurationmanager_interface.h @@ -244,11 +244,6 @@ DRING_PUBLIC void connectivityChanged(); /* Dht proxy */ -/** - * Start or stop to use the proxy for account - */ -DRING_PUBLIC void enableProxyClient(const std::string& accountID, bool enable); - /** * Set the device push notification token (for all accounts). * If set, proxy clients will use push notifications. diff --git a/src/jamidht/jamiaccount.cpp b/src/jamidht/jamiaccount.cpp index 82a2afd402..51fac8784f 100644 --- a/src/jamidht/jamiaccount.cpp +++ b/src/jamidht/jamiaccount.cpp @@ -3486,15 +3486,6 @@ JamiAccount::closePeerConnection(const DRing::DataTransferId& tid) dhtPeerConnector_->closeConnection(tid); } -void -JamiAccount::enableProxyClient(bool enable) -{ - JAMI_WARN("[Account %s] DHT proxy client: %s", - getAccountID().c_str(), - enable ? "enable" : "disable"); - dht_->enableProxy(enable); -} - void JamiAccount::setPushNotificationToken(const std::string& token) { diff --git a/src/jamidht/jamiaccount.h b/src/jamidht/jamiaccount.h index 8f876c0940..a50a74bae0 100644 --- a/src/jamidht/jamiaccount.h +++ b/src/jamidht/jamiaccount.h @@ -420,13 +420,6 @@ public: std::function<void(const std::shared_ptr<dht::crypto::PublicKey>&)>&& op, std::function<void(bool)>&& end = {}); - /** - * Start or stop to use the proxy client - * @param address of the proxy - * @param deviceKey the device key for push notifications (empty to not use it) - */ - void enableProxyClient(bool enable); - void setPushNotificationToken(const std::string& pushDeviceToken = "") override; void setPushNotificationTopic(const std::string& topic) override; -- GitLab