From bd4f71a97da9602ba9cde95c21aad8fa1e8f37de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Taavi=20V=C3=A4=C3=A4n=C3=A4nen?= Date: Tue, 5 Nov 2024 20:53:08 +0200 Subject: [PATCH] TOTPSecondaryAuthenticationProvider: Avoid use of getModule() Change-Id: Iec9be88a8e189b84263e0b2f567d7288b4e4321e --- src/Auth/TOTPSecondaryAuthenticationProvider.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Auth/TOTPSecondaryAuthenticationProvider.php b/src/Auth/TOTPSecondaryAuthenticationProvider.php index 42bca642..cfd1ce4b 100644 --- a/src/Auth/TOTPSecondaryAuthenticationProvider.php +++ b/src/Auth/TOTPSecondaryAuthenticationProvider.php @@ -67,7 +67,7 @@ class TOTPSecondaryAuthenticationProvider extends AbstractSecondaryAuthenticatio public function beginSecondaryAuthentication( $user, array $reqs ) { $authUser = $this->userRepository->findByUser( $user ); - if ( !( $authUser->getModule() instanceof TOTP ) ) { + if ( !$this->module->isEnabled( $authUser ) ) { return AuthenticationResponse::newAbstain(); }