I am using firebase for user authentication in my website. Trying to build a password reset flow where the user receives password reset email, reset's their password and then it is just redirect to the website with the given url.
Problem: I am able to send the password reset email and change the password for that account but when I click the continue button provided by the firebase.It throws following error in browser console.
Uncaught DOMException: Failed to execute 'assign' on 'Location':
'https://?link=http://mywebsite.com/?email%[email protected]' is not a valid URL.
I am also getting the same error for email verification link also.
The url is whitelisted in Firebase's authorized domains.
Please help me!
Are you passing canHandleCodeInApp
as true? This means you want the reset link to open in a mobile app if installed. If so, it looks like your FDL domain is not configured (it is resolving to empty string). You should go to the Dynamic links section in the Firebase Console and setup/agree to terms of service. This will update the link to something like: https://example.app.goo.gl/?link=....
You will be able to see that domain in the Console Dynamic links section.
Otherwise you can pass canHandleCodeInApp
as false which would open the link via the web action callback URL set up in the email templates section of the Firebase Console. This link will not go through FDL unlike the latter.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With