payload icon indicating copy to clipboard operation
payload copied to clipboard

Reset Password form is not running beforeValidate hook

Open carlcs opened this issue 6 months ago • 1 comments

Link to reproduction

No response

Payload Version

3.0.0-beta.74

Node Version

v20.15.1

Next.js Version

15.0.0-canary.53

Describe the Bug

We’ve got a beforeValidate hook setup for our users collection to enforce secure passwords (min length and other validations). This works well in the create and edit user forms in the admin panel

The reset password form doesn’t run the hook, I can update the password to "1234".

Reproduction Steps

  1. Have beforeValidate hook in place
  2. Test hook in admin panel, password "1234" cannot be saved
  3. Go through "Forgot password?" process to see reset password form
  4. Set "1234" as new password

Adapters and Plugins

db-mongodb, email-nodemailer, storage-s3

carlcs avatar Aug 08 '24 09:08 carlcs