Skip to content

skipIsVerifiedCheck doesn't call custom notifier. #172

@MartynasRaf

Description

@MartynasRaf

Steps to reproduce

When implementing auth management, I have set up email verification and reset password functionality. The problem I'm getting is when I'm trying to bypass the check for email verification when resetting the password.

Curently I'm setting it up like this:

app.configure(authentication).configure( authManagement({ skipIsVerifiedCheck: true, notifier: (type, user, notifierOptions) => notifier(type, user, notifierOptions), }) );

The whole code is very similar to this tutorial: https://hackernoon.com/setting-up-email-verification-in-feathersjs-ce764907e4f2
Except for minor details such as sendResetPwd and resetPwd filled out to include email subject and body and reset route which all work when user is verified.

And while the email verification works fine and sends the email to the client, when sending a post request to reset the password returns the response as if it has been reset, but no email has been sent as though the call didn't go through. When checked in the database the user has been modified with exactly the same entry (password, email, etc.) so it bypassed my custom logic and just reset the password to itself it seems.

Tested it with console logs and it definitely doesn't go through my notifier when using skipISVerifiedCheck option.

Expected behavior

Tell us what should happen

When POST request has been received the service should skip checking the verification field and call my notifier with "sendResetPwd" action.

Actual behavior

Tell us what happens instead

When POST request has been received the service skips checking the verification field but doesn't call my notifier with the action.

System configuration

Tell us about the applicable parts of your setup.

Module versions (especially the part that's not working):

"feathers-authentication-management": "^3.1.0",
"@feathersjs/feathers": "^4.5.12",

NodeJS version:

Operating System:

Win11

Browser Version:

React Native Version:

Module Loader:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions