Skip to content

Commit

Permalink
Merge pull request #861 from yaroslawww/patch-1
Browse files Browse the repository at this point in the history
Update TokenGuard.php
  • Loading branch information
taylorotwell authored Oct 30, 2018
2 parents 0f8668f + 2d778c9 commit 039de8b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Guards/TokenGuard.php
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ protected function authenticateViaBearerToken($request)
// associated with the token. We will use the provider implementation which may
// be used to retrieve users from Eloquent. Next, we'll be ready to continue.
$user = $this->provider->retrieveById(
$psr->getAttribute('oauth_user_id')
$psr->getAttribute('oauth_user_id') ?: null
);

if (! $user) {
Expand Down

0 comments on commit 039de8b

Please sign in to comment.