From: Julius Härtl Date: Thu, 2 Apr 2020 15:07:53 +0000 (+0200) Subject: Query Application class on publicwebdav X-Git-Tag: v19.0.0beta1~5^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fpull%2F20275%2Fhead;p=nextcloud-server.git Query Application class on publicwebdav Signed-off-by: Julius Härtl --- diff --git a/apps/dav/appinfo/v1/publicwebdav.php b/apps/dav/appinfo/v1/publicwebdav.php index e7bd867898e..c50bc134131 100644 --- a/apps/dav/appinfo/v1/publicwebdav.php +++ b/apps/dav/appinfo/v1/publicwebdav.php @@ -65,7 +65,7 @@ $filesDropPlugin = new \OCA\DAV\Files\Sharing\FilesDropPlugin(); $server = $serverFactory->createServer($baseuri, $requestUri, $authPlugin, function (\Sabre\DAV\Server $server) use ($authBackend, $linkCheckPlugin, $filesDropPlugin) { $isAjax = (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && $_SERVER['HTTP_X_REQUESTED_WITH'] === 'XMLHttpRequest'); - $federatedSharingApp = new \OCA\FederatedFileSharing\AppInfo\Application(); + $federatedSharingApp = \OC::$server->query(\OCA\FederatedFileSharing\AppInfo\Application::class); $federatedShareProvider = $federatedSharingApp->getFederatedShareProvider(); if ($federatedShareProvider->isOutgoingServer2serverShareEnabled() === false && !$isAjax) { // this is what is thrown when trying to access a non-existing share