Skip to content

Commit 58dc085

Browse files
committed
feat: return user in token after verification
1 parent eccdf35 commit 58dc085

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Auth.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -745,6 +745,7 @@ public function parseToken()
745745
/**
746746
* Verify a user's token
747747
* @param string $token The token to verify
748+
* @return User|null
748749
*/
749750
public function verifyToken(string $token)
750751
{
@@ -771,7 +772,7 @@ public function verifyToken(string $token)
771772
return null;
772773
}
773774

774-
return true;
775+
return $user;
775776
} catch (\Throwable $th) {
776777
$this->errorsArray['token'] = $th->getMessage();
777778
return null;

0 commit comments

Comments
 (0)