summary refs log tree commit diff
path: root/src/DeviceVerificationFlow.cpp
diff options
context:
space:
mode:
authorDeepBlueV7.X <nicolas.werner@hotmail.de>2020-10-28 14:50:00 +0100
committerGitHub <noreply@github.com>2020-10-28 14:50:00 +0100
commitfd4f173966e1d7d4d6c40d07da2f2efa270afc82 (patch)
tree2770e82ae26157d69c5158e76de39129ddc57864 /src/DeviceVerificationFlow.cpp
parentTranslated using Weblate (Russian) (diff)
parentDon't pass around empty timeline (diff)
downloadnheko-fd4f173966e1d7d4d6c40d07da2f2efa270afc82.tar.xz
Merge pull request #308 from Nheko-Reborn/build-opt
Optimize build
Diffstat (limited to 'src/DeviceVerificationFlow.cpp')
-rw-r--r--src/DeviceVerificationFlow.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/DeviceVerificationFlow.cpp b/src/DeviceVerificationFlow.cpp

index aa1a9607..509fce8c 100644 --- a/src/DeviceVerificationFlow.cpp +++ b/src/DeviceVerificationFlow.cpp
@@ -1,8 +1,10 @@ #include "DeviceVerificationFlow.h" #include "Cache.h" +#include "Cache_p.h" #include "ChatPage.h" #include "Logging.h" +#include "Utils.h" #include "timeline/TimelineModel.h" #include <QDateTime> @@ -39,7 +41,7 @@ DeviceVerificationFlow::DeviceVerificationFlow(QObject *, auto user_id = userID.toStdString(); this->toClient = mtx::identifiers::parse<mtx::identifiers::User>(user_id); - ChatPage::instance()->query_keys( + cache::client()->query_keys( user_id, [user_id, this](const UserKeyCache &res, mtx::http::RequestErr err) { if (err) { nhlog::net()->warn("failed to query device keys: {},{}", @@ -57,7 +59,7 @@ DeviceVerificationFlow::DeviceVerificationFlow(QObject *, this->their_keys = res; }); - ChatPage::instance()->query_keys( + cache::client()->query_keys( http::client()->user_id().to_string(), [this](const UserKeyCache &res, mtx::http::RequestErr err) { if (err) {