Open mhuebert opened 6 years ago
Thanks for filing. I can recreate this. I suspect it may be an issue with updateCurrentUser
.
It is unrelated to FirebaseUI and the root cause is likely in the firebase-js-sdk.
I think I jumped to the wrong conclusion. It appears to be the behavior in FirebaseUI. We call reset() after signInSuccess triggers which sets the original languageCode on the Auth instance overwriting your value. https://github.com/firebase/firebaseui-web/blob/master/javascript/widgets/authui.js#L671 There is a race condition here. By the time the email verification is sent, the original language code is set again (null in this case).
Thanks for looking into this. Yes, I can confirm that if I add a timeout of 0 (before I set the language code and trigger the email), the race condition is avoided and I am able to set the language.
Still happening, event with a 1 second timeout
This should have been fixed in v3.4.1. Make sure to upgrade to 3.4.1+
The docs say that one can set the language code for the email verification flow like so:
I can't seem to get this to work -- no matter what I do, the email and verification page remain in English. I have created a minimal reproduction using the following success callback:
The verification email is sent, but the language remains English, instead of being set to french.
Minimal reproduction: