Closed ewwwgiddings closed 3 minutes ago
Yes, this is currently missing. Would you be willing to create a PR?
Willing to try my hand at it: https://github.com/capawesome-team/capacitor-firebase/pull/741
I haven't had any experience til now working on Capacitor plugins, but I created this PR just now.
I used the sendEmailVerification
and updateEmail
methods as a guide and did a bunch of copy/paste/rename from those.
Didn't click any of the buttons on the PR checklist cause I'm not sure how it's tested.
Maybe someone else who has more knowledge on the subject can review, suggest, or edit the PR if it's not far off?
Closed by #741
Plugin(s)
Current problem
When selecting email enumeration protection it is said that we should not be using
updateEmail()
and instead useverifyBeforeUpdateEmail()
: Firebase Doc ReferenceHere is some more information about it: Email Enumeration Docs
As said in the above document:
This is a part of the same documentation for the deprecation of
fetchsigninmethodsforemail()
so it has been considered for other methods.While we can use the JS SDK for this it is not available for the Android and iOS implementations of this plugin as far as I can tell.****
Preferred solution
Add the ability to use
verifyBeforeUpdateEmail()
andsendEmailVerification(beforeUpdatingEmail:)
depending on the environment, or have one method that will do it as it differs with iOS under-the-hood.Alternative options
I think I can only easily achieve this on web by using JS SDK as noted in some other workarounds.
If there is a way I can achieve this without adding this method to this plugin I would love to hear how.
Additional context
When attempting to use the
fetchsigninmethodsforemail()
method I Noticed it was deprecated and followed the links to find out I should also not be usingupdateEmail()
if I want to turn off email enumeration protection (which imo should be turned on)Before submitting