Skip to content

Commit

Permalink
fix: incompatibility with Symfony 7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
endroid committed Nov 29, 2024
1 parent c30b61e commit ecd09f0
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/Security/Http/Firewall/RefreshAccessTokenListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,16 @@

use HWI\Bundle\OAuthBundle\Security\Core\Authentication\Token\OAuthToken;
use HWI\Bundle\OAuthBundle\Security\Http\Authenticator\OAuthAuthenticator;
use Symfony\Component\Security\Http\Authenticator\AuthenticatorInterface;

class RefreshAccessTokenListener extends AbstractRefreshAccessTokenListener
{
private OAuthAuthenticator $oAuthAuthenticator;
private AuthenticatorInterface $authenticator;

public function __construct(
OAuthAuthenticator $oAuthAuthenticator
AuthenticatorInterface $authenticator
) {
$this->oAuthAuthenticator = $oAuthAuthenticator;
$this->authenticator = $authenticator;
}

/**
Expand All @@ -33,6 +34,6 @@ public function __construct(
*/
protected function refreshToken(OAuthToken $token): OAuthToken
{
return $this->oAuthAuthenticator->refreshToken($token);
return $this->authenticator->refreshToken($token);

Check failure on line 37 in src/Security/Http/Firewall/RefreshAccessTokenListener.php

View workflow job for this annotation

GitHub Actions / phpstan

Call to an undefined method Symfony\Component\Security\Http\Authenticator\AuthenticatorInterface::refreshToken().
}
}

0 comments on commit ecd09f0

Please sign in to comment.