@@ -169,7 +169,7 @@ discard block |
||
| 169 | 169 | $error = $e->getCode() === InvalidTokenException::TOKEN_EXPIRED |
| 170 | 170 | ? $this->l10n->t('Could not reset password because the token is expired') |
| 171 | 171 | : $this->l10n->t('Could not reset password because the token is invalid'); |
| 172 | - throw new Exception($error, (int)$e->getCode(), $e); |
|
| 172 | + throw new Exception($error, (int) $e->getCode(), $e); |
|
| 173 | 173 | } |
| 174 | 174 | } |
| 175 | 175 | |
@@ -202,7 +202,7 @@ discard block |
||
| 202 | 202 | $this->sendEmail($user); |
| 203 | 203 | } catch (ResetPasswordException $e) { |
| 204 | 204 | // Ignore the error since we do not want to leak this info |
| 205 | - $this->logger->warning('Could not send password reset email: ' . $e->getMessage()); |
|
| 205 | + $this->logger->warning('Could not send password reset email: '.$e->getMessage()); |
|
| 206 | 206 | } catch (Exception $e) { |
| 207 | 207 | $this->logger->error($e->getMessage(), ['exception' => $e]); |
| 208 | 208 | } |
@@ -264,7 +264,7 @@ discard block |
||
| 264 | 264 | $email = $user->getEMailAddress(); |
| 265 | 265 | |
| 266 | 266 | if (empty($email)) { |
| 267 | - throw new ResetPasswordException('Could not send reset e-mail since there is no email for username ' . $input); |
|
| 267 | + throw new ResetPasswordException('Could not send reset e-mail since there is no email for username '.$input); |
|
| 268 | 268 | } |
| 269 | 269 | |
| 270 | 270 | // Generate the token. It is stored encrypted in the database with the |
@@ -314,13 +314,13 @@ discard block |
||
| 314 | 314 | $user = $this->userManager->get($input); |
| 315 | 315 | if ($user instanceof IUser) { |
| 316 | 316 | if (!$user->isEnabled()) { |
| 317 | - throw new ResetPasswordException('User ' . $user->getUID() . ' is disabled'); |
|
| 317 | + throw new ResetPasswordException('User '.$user->getUID().' is disabled'); |
|
| 318 | 318 | } |
| 319 | 319 | |
| 320 | 320 | return $user; |
| 321 | 321 | } |
| 322 | 322 | |
| 323 | - $users = array_filter($this->userManager->getByEmail($input), function (IUser $user) { |
|
| 323 | + $users = array_filter($this->userManager->getByEmail($input), function(IUser $user) { |
|
| 324 | 324 | return $user->isEnabled(); |
| 325 | 325 | }); |
| 326 | 326 | |
@@ -328,6 +328,6 @@ discard block |
||
| 328 | 328 | return reset($users); |
| 329 | 329 | } |
| 330 | 330 | |
| 331 | - throw new ResetPasswordException('Could not find user ' . $input); |
|
| 331 | + throw new ResetPasswordException('Could not find user '.$input); |
|
| 332 | 332 | } |
| 333 | 333 | } |