From 59c746cdea6b5dff3f687e62e2a8b8723a133fca Mon Sep 17 00:00:00 2001 From: Henjo Hoeksma Date: Wed, 17 May 2023 11:17:37 +0200 Subject: [PATCH 1/2] fix: Union type is not supported < php 8.0 --- Classes/Http/Middleware/SecondFactorMiddleware.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Classes/Http/Middleware/SecondFactorMiddleware.php b/Classes/Http/Middleware/SecondFactorMiddleware.php index aa2f752..f83be12 100644 --- a/Classes/Http/Middleware/SecondFactorMiddleware.php +++ b/Classes/Http/Middleware/SecondFactorMiddleware.php @@ -228,7 +228,7 @@ private function registerOriginalRequestForRedirect(ServerRequestInterface $requ $this->securityContext->setInterceptedRequest($actionRequest); } - private function log(string|\Stringable $message, array $context = []): void + private function log(string $message, array $context = []): void { $this->securityLogger->debug(self::LOGGING_PREFIX . $message, $context); } From d21d304bcfaa20360065fef02917c289a662e915 Mon Sep 17 00:00:00 2001 From: Henjo Hoeksma Date: Wed, 17 May 2023 11:23:16 +0200 Subject: [PATCH 2/2] fix: Unexpected return type --- Classes/Service/TOTPService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Classes/Service/TOTPService.php b/Classes/Service/TOTPService.php index 901a321..086ffe3 100644 --- a/Classes/Service/TOTPService.php +++ b/Classes/Service/TOTPService.php @@ -35,7 +35,7 @@ public static function checkIfOtpIsValid(string $secret, string $submittedOtp): return $otp->verify($submittedOtp); } - public function generateQRCodeForTokenAndAccount(TOTP $otp, Account $account): mixed + public function generateQRCodeForTokenAndAccount(TOTP $otp, Account $account): string { $secret = $otp->getSecret();