From deb598bbe5bc6b49a69426671faee6867001c8bf Mon Sep 17 00:00:00 2001 From: Daniel Seifert Date: Wed, 9 Nov 2022 12:04:35 +0100 Subject: [PATCH] rename module methods in extended OXID classes to prevent conflicts with other modules --- src/Application/Controller/Traits/checkoutGetUserTrait.php | 4 ++-- .../Controller/Admin/d3_LoginController_Webauthn.php | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Application/Controller/Traits/checkoutGetUserTrait.php b/src/Application/Controller/Traits/checkoutGetUserTrait.php index f49bfc9..1902498 100755 --- a/src/Application/Controller/Traits/checkoutGetUserTrait.php +++ b/src/Application/Controller/Traits/checkoutGetUserTrait.php @@ -42,7 +42,7 @@ trait checkoutGetUserTrait $webauthn = $this->d3GetWebauthnObject(); if ($webauthn->isActive($user->getId()) - && !$this->d3GetSessionObject()->getVariable(WebauthnConf::WEBAUTHN_SESSION_AUTH) + && !$this->d3WebauthnGetSessionObject()->getVariable(WebauthnConf::WEBAUTHN_SESSION_AUTH) ) { return false; } @@ -62,7 +62,7 @@ trait checkoutGetUserTrait /** * @return Session */ - public function d3GetSessionObject(): Session + public function d3WebauthnGetSessionObject(): Session { return Registry::getSession(); } diff --git a/src/Modules/Application/Controller/Admin/d3_LoginController_Webauthn.php b/src/Modules/Application/Controller/Admin/d3_LoginController_Webauthn.php index def0ba8..be68c62 100755 --- a/src/Modules/Application/Controller/Admin/d3_LoginController_Webauthn.php +++ b/src/Modules/Application/Controller/Admin/d3_LoginController_Webauthn.php @@ -49,7 +49,7 @@ class d3_LoginController_Webauthn extends d3_LoginController_Webauthn_parent $password = Registry::getRequest()->getRequestParameter('pwd'); /** @var d3_User_Webauthn $user */ - $user = $this->d3GetUserObject(); + $user = $this->d3WebauthnGetUserObject(); $userId = $user->d3GetLoginUserId($lgn_user, 'malladmin'); if ($lgn_user && $userId && @@ -86,14 +86,14 @@ class d3_LoginController_Webauthn extends d3_LoginController_Webauthn_parent */ public function d3WebauthnCancelLogin(): void { - $oUser = $this->d3GetUserObject(); + $oUser = $this->d3WebauthnGetUserObject(); $oUser->logout(); } /** * @return User */ - public function d3GetUserObject(): User + public function d3WebauthnGetUserObject(): User { return oxNew(User::class); }