Skip to content

Commit

Permalink
[5.x] fix: remove typehint to be compatible with Socialite AbstractPr…
Browse files Browse the repository at this point in the history
…ovider (#330)
  • Loading branch information
okaufmann authored Jan 23, 2024
1 parent aa7755a commit 6469281
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Concerns/RefreshesOAuth2Tokens.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,12 @@ trait RefreshesOAuth2Tokens
*
* @throws GuzzleException
*/
public function refreshToken(ConnectedAccount $connectedAccount): RefreshedCredentials
public function refreshToken($connectedAccount): RefreshedCredentials
{
if(!$connectedAccount instanceof ConnectedAccount) {
throw new \RuntimeException('Given parameter must be of type ConnectedAccount.');
}

if (is_null($connectedAccount->refresh_token)) {
throw new \RuntimeException('A valid refresh token is required.');
}
Expand Down

0 comments on commit 6469281

Please sign in to comment.