diff --git a/lib/UserBackend.php b/lib/UserBackend.php index 20717a5c3..4856344b2 100644 --- a/lib/UserBackend.php +++ b/lib/UserBackend.php @@ -11,6 +11,7 @@ use OCA\User_SAML\Model\SessionData; use OCP\Authentication\IApacheBackend; use OCP\EventDispatcher\IEventDispatcher; +use OCP\Files\IRootFolder; use OCP\Files\NotPermittedException; use OCP\IConfig; use OCP\IDBConnection; @@ -118,7 +119,7 @@ public function createUserIfNotExists(string $uid, array $attributes = []): void public function initializeHomeDir(string $uid): void { ### Code taken from lib/private/User/Session.php - function prepareUserLogin() ### //trigger creation of user home and /files folder - $userFolder = \OC::$server->getUserFolder($uid); + $userFolder = Server::get(IRootFolder::class)->getUserFolder($uid); try { // copy skeleton \OC_Util::copySkeleton($uid, $userFolder); diff --git a/templates/admin.php b/templates/admin.php index 2534fe997..1bacd3210 100644 --- a/templates/admin.php +++ b/templates/admin.php @@ -7,6 +7,8 @@ style('user_saml', 'admin'); /** @var array $_ */ +$urlGenerator = \OCP\Server::get(\OCP\IURLGenerator::class); + ?>

t('SSO & SAML authentication')); ?>

@@ -20,7 +22,7 @@ - + t('Download metadata XML')) ?> diff --git a/tests/psalm-baseline.xml b/tests/psalm-baseline.xml index 4dfbc8211..e21beaf45 100644 --- a/tests/psalm-baseline.xml +++ b/tests/psalm-baseline.xml @@ -3,7 +3,7 @@ - SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors - SPDX-License-Identifier: AGPL-3.0-or-later --> - + @@ -43,9 +43,12 @@ + + + - +