1
0
mirror of https://github.com/delight-im/PHP-Auth.git synced 2025-07-31 13:20:11 +02:00

Document 'Auth#resetPasswordAndSignIn' in README

This commit is contained in:
Marco
2020-04-20 21:36:08 +02:00
parent 0086419175
commit dcd893a12c

View File

@@ -350,6 +350,8 @@ catch (\Delight\Auth\TooManyRequestsException $e) {
}
```
Do you want to have the respective user signed in automatically when their password reset succeeds? Simply use `Auth#resetPasswordAndSignIn` instead of `Auth#resetPassword` to log in the user immediately.
If you need the users ID or email address, e.g. for sending them a notification that their password has successfully been reset, just use the return value of `Auth#resetPassword`, which is an array containing two entries named `id` and `email`.
### Changing the current users password