@@ -113,7 +113,7 @@ |
||
113 | 113 | /** |
114 | 114 | * Get valid. |
115 | 115 | * |
116 | - * @return \DateTime |
|
116 | + * @return string |
|
117 | 117 | */ |
118 | 118 | public function getValid() |
119 | 119 | { |
@@ -67,7 +67,7 @@ |
||
67 | 67 | /** |
68 | 68 | * Get user. |
69 | 69 | * |
70 | - * @return $username |
|
70 | + * @return string |
|
71 | 71 | */ |
72 | 72 | public function getUsername(); |
73 | 73 |
@@ -49,7 +49,7 @@ |
||
49 | 49 | * |
50 | 50 | * @param Request $request |
51 | 51 | * |
52 | - * @return mixed |
|
52 | + * @return \Symfony\Component\HttpFoundation\Response|\Lexik\Bundle\JWTAuthenticationBundle\Response\JWTAuthenticationSuccessResponse |
|
53 | 53 | * |
54 | 54 | * @throws AuthenticationException |
55 | 55 | */ |
@@ -43,8 +43,9 @@ |
||
43 | 43 | $this->requestStack = $requestStack; |
44 | 44 | $this->userManager = $userManager; |
45 | 45 | $this->getUsername = 'getUsername'; |
46 | - if ($getUsername) |
|
47 | - $this->getUsername = $getUsername; |
|
46 | + if ($getUsername) { |
|
47 | + $this->getUsername = $getUsername; |
|
48 | + } |
|
48 | 49 | } |
49 | 50 | |
50 | 51 | public function attachRefreshToken(AuthenticationSuccessEvent $event) |
@@ -106,11 +106,11 @@ |
||
106 | 106 | } |
107 | 107 | |
108 | 108 | /** |
109 | - * @param RefreshTokenInterface[] $tokens |
|
110 | - * @param bool $andFlush |
|
111 | - * |
|
112 | - * @return RefreshTokenInterface[] |
|
113 | - */ |
|
109 | + * @param RefreshTokenInterface[] $tokens |
|
110 | + * @param bool $andFlush |
|
111 | + * |
|
112 | + * @return RefreshTokenInterface[] |
|
113 | + */ |
|
114 | 114 | public function revokeTokens($tokens, $andFlush) |
115 | 115 | { |
116 | 116 | foreach ($tokens as $token) { |
@@ -65,8 +65,9 @@ |
||
65 | 65 | public function save(RefreshTokenInterface $refreshToken, $andFlush = true) |
66 | 66 | { |
67 | 67 | $offset = $this->maxTokenByUser; |
68 | - if (!$andFlush) |
|
69 | - $offset--; |
|
68 | + if (!$andFlush) { |
|
69 | + $offset--; |
|
70 | + } |
|
70 | 71 | $username = $refreshToken->getUsername(); |
71 | 72 | $this->objectManager->persist($refreshToken); |
72 | 73 |