diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2021-02-10 15:41:25 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2021-02-10 15:41:25 +0100 |
commit | 25f9203a702cb71be5221214d9c46869b1c2cb79 (patch) | |
tree | b7e0ebb6f301662af7a0d2b787cd3895ada691f3 /lib/private | |
parent | 2f26ff40e9aaabd1c8cc2167dea2158a22b1961f (diff) | |
download | nextcloud-server-25f9203a702cb71be5221214d9c46869b1c2cb79.tar.gz nextcloud-server-25f9203a702cb71be5221214d9c46869b1c2cb79.zip |
Fix remaining #25359
As a wise man once said:
"I like PRs that pass tests before merging"
C. Wurst, Feb 9th 2021
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/AppFramework/Bootstrap/RegistrationContext.php | 5 | ||||
-rw-r--r-- | lib/private/legacy/OC_App.php | 10 |
2 files changed, 6 insertions, 9 deletions
diff --git a/lib/private/AppFramework/Bootstrap/RegistrationContext.php b/lib/private/AppFramework/Bootstrap/RegistrationContext.php index 619e4f55011..fc13a78f3d3 100644 --- a/lib/private/AppFramework/Bootstrap/RegistrationContext.php +++ b/lib/private/AppFramework/Bootstrap/RegistrationContext.php @@ -271,10 +271,7 @@ class RegistrationContext { } public function registerTemplateProvider(string $appId, string $class): void { - $this->templateProviders[] = [ - 'appId' => $appId, - 'class' => $class, - ]; + $this->templateProviders[] = new ServiceRegistration($appId, $class); } /** diff --git a/lib/private/legacy/OC_App.php b/lib/private/legacy/OC_App.php index 530291002bb..d48d6c40810 100644 --- a/lib/private/legacy/OC_App.php +++ b/lib/private/legacy/OC_App.php @@ -709,12 +709,12 @@ class OC_App { try { /** @var IAlternativeLogin $provider */ - $provider = \OC::$server->query($registration['class']); + $provider = \OC::$server->query($registration->getService()); } catch (QueryException $e) { \OC::$server->getLogger()->logException($e, [ 'message' => 'Alternative login option {option} can not be initialised.', - 'option' => $registration['class'], - 'app' => $registration['app'], + 'option' => $registration->getService(), + 'app' => $registration->getAppId(), ]); } @@ -729,8 +729,8 @@ class OC_App { } catch (Throwable $e) { \OC::$server->getLogger()->logException($e, [ 'message' => 'Alternative login option {option} had an error while loading.', - 'option' => $registration['class'], - 'app' => $registration['app'], + 'option' => $registration->getService(), + 'app' => $registration->getAppId(), ]); } } |