Open Boardtale opened 7 months ago
i can fix this @Boardtale can i work on this??
Hi @Boardtale, thanks for reporting this. I agree that signInFailure
should trigger if account creation or sign-in is blocked by a blocking function. We'll mark this as a bug.
As a side note, would email link authentication be a better fit for your use case than email + password?
What are your difficulties problem
On Thursday, March 7, 2024, Thanush19 @.***> wrote:
i can fix this @Boardtale https://github.com/Boardtale can i work on this??
— Reply to this email directly, view it on GitHub https://github.com/firebase/firebaseui-web/issues/1074#issuecomment-1982335568, or unsubscribe https://github.com/notifications/unsubscribe-auth/A2WGGN7R5I7VEESS6OKV6TLYW7VZDAVCNFSM6AAAAABED3R3ECVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOBSGMZTKNJWHA . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Glad that I can confirm that I am not the only one experiencing this. My case is really similar where I am blocking user creation in the beforeCreate blocking function, returning a custom error that I prepare to catch and handle on the frontend to display a user-friendly error. Unfortunately I am in the same boat here @Boardtale , there seems no way to catch this error anywhere.
The only potential approach for me now is to use firebase SDK to initiate sign in flow which then defeats the purpose of me using this library.
Edit: Sorry I did not mention this, but for me this happens when a user tries to sign up using a Social sign in (Google/Microsoft).
Need:
I require for email + pwd to verify emails. As far as I know, I can't prevent or redirect flow after user first time creates account. So the error is sent from my blocking function: 'please verify email'. That does not look good when user tries to log in with unverfied email: I want to catch that error and show proper error popup for the users.
I am using 'signInFailure' but it's not triggered.. I think ever :P I don't know where it's triggered but not if I get any forbidden from my blocking function
So I'd like to solve it somehow. I see few paths but neither is possible - afaik - with firebaseUI. Unless I'm gonna dirty trick it and break encapsulation.
EDIT:
I guess I could do this manually on my own backend, after login, check if verified email and then redirect them also logging them out. But that's many additional actions