Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

verificationRequest removed from signin callback, incorrect documentation #1251

Closed
kriscarle opened this issue Feb 4, 2021 · 2 comments · Fixed by #1258
Closed

verificationRequest removed from signin callback, incorrect documentation #1251

kriscarle opened this issue Feb 4, 2021 · 2 comments · Fixed by #1258
Labels
bug Something isn't working hacktoberfest Good issue to take for first time contributors

Comments

@kriscarle
Copy link
Contributor

The documentation for the signin callback at https://next-auth.js.org/configuration/callbacks#sign-in-callback says

Email accounts do not have profiles in the same way OAuth accounts do. On the first call during email sign in the profile object will include an property verificationRequest: true to indicate it is being triggered in the verification request flow. When the callback is invoked after a user has clicked on a sign in link, this property will not be present.

You can check for the verificationRequest property to avoid sending emails to addresses or domains on a blocklist (or to only explicitly generate them for email address in an allow list).

Looking at the history it appears to have been removed in #959 here:

https://github.com/nextauthjs/next-auth/pull/959/files#diff-273ce1b1ba70a2520a63bb41cff4da08d8272e82a43dc57b9e9a402daf26621dL57

Possibly just a bug? Would it be safe to add verificationRequest: true back in that line?

@kriscarle kriscarle added the bug Something isn't working label Feb 4, 2021
@balazsorban44
Copy link
Member

yes, that looks like it was removed by accident, thanks for tracking this issue down! are you interested in opening a PR with the fix?

@github-actions
Copy link

github-actions bot commented Feb 4, 2021

🎉 This issue has been resolved in version 3.3.0-canary.5 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working hacktoberfest Good issue to take for first time contributors
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants