diff --git a/src/Authenticator.php b/src/Authenticator.php index 33881b5..2df7e72 100644 --- a/src/Authenticator.php +++ b/src/Authenticator.php @@ -155,7 +155,7 @@ public function getLostPasswordHandler($link) * @param ValidationResult $result A validationresult which is either valid or contains the error message(s) * @return Member The matched member, or null if the authentication fails */ - public function authenticate(array $data, HTTPRequest $request, ValidationResult &$result = null) + public function authenticate(array $data, HTTPRequest $request, ?ValidationResult &$result = null) { try { $this->service->enforceLogin($request); @@ -189,7 +189,7 @@ public function authenticate(array $data, HTTPRequest $request, ValidationResult * @param ValidationResult $result * @return ValidationResult */ - public function checkPassword(Member $member, $password, ValidationResult &$result = null) + public function checkPassword(Member $member, $password, ?ValidationResult &$result = null) { // No-op } diff --git a/src/RealMeService.php b/src/RealMeService.php index c874625..347edca 100644 --- a/src/RealMeService.php +++ b/src/RealMeService.php @@ -907,7 +907,7 @@ private function getRequestedAuthnContext() * * @return Auth */ - public function getAuth(HTTPRequest $request = null) + public function getAuth(?HTTPRequest $request = null) { if (isset($this->auth)) { return $this->auth;