From 43b7ae55df05759c29f86811935edd3f267447c4 Mon Sep 17 00:00:00 2001 From: Claudio Cambra Date: Tue, 2 Jan 2024 17:04:45 +0800 Subject: [PATCH] Use accountStateFromFileProviderDomainIdentifier method in authenticateExtension Signed-off-by: Claudio Cambra --- src/gui/macOS/fileproviderxpc_mac.mm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/gui/macOS/fileproviderxpc_mac.mm b/src/gui/macOS/fileproviderxpc_mac.mm index a18bccdbc..126242277 100644 --- a/src/gui/macOS/fileproviderxpc_mac.mm +++ b/src/gui/macOS/fileproviderxpc_mac.mm @@ -17,6 +17,7 @@ #include #include "gui/accountmanager.h" +#include "gui/macOS/fileproviderdomainmanager.h" #include "gui/macOS/fileproviderxpc_mac_utils.h" namespace OCC::Mac { @@ -48,9 +49,7 @@ void FileProviderXPC::configureExtensions() void FileProviderXPC::authenticateExtension(const QString &extensionAccountId) const { - const auto accountManager = AccountManager::instance(); - Q_ASSERT(accountManager); - const auto accountState = accountManager->accountFromUserId(extensionAccountId); + const auto accountState = FileProviderDomainManager::accountStateFromFileProviderDomainIdentifier(extensionAccountId); if (!accountState) { qCWarning(lcFileProviderXPC) << "Account state is null for received account" << extensionAccountId;