-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Closed
Labels
StaleIssue with no recent activityIssue with no recent activityclosed-by-botplatform: webIssues / PRs which are specifically for web.Issues / PRs which are specifically for web.plugin: authresolution: fixedA fix has been merged or is pending merge from a PR.A fix has been merged or is pending merge from a PR.type: bugSomething isn't workingSomething isn't working
Description
Bug report
Describe the bug
userChanges is streamed when we call linkWithCredential on the user, and it works fine on android, but when on chrome it streams data before the link happens, so if you check if the user isAnonymous on a listener you will see it will still be anonymous
Steps to reproduce
- Initialize firebase as you would
- Listen to the userChanges stream
FirebaseAuth.instance.userChanges().listen((event) { print("User updated: ${event}"); }); - SignIn anonymously
auth.FirebaseAuth.instance.signInAnonymously(); - Link the anonymous account
auth.FirebaseAuth.instance.currentUser!.linkWithCredential(EmailAuthProvider.credential(email: "dsadsa@dasdas.dasdsa", password: "dasdsadsa",),); - Now build for android and see it working as expected
- Then build for chrome and see that after linking the account you will receive an update on the stream but the account they give you on the stream will still not be linked
Expected behavior
For the stream be updated after the user get linked not before
Sample project
Providing a minimal example project which demonstrates the bug in isolation from your main App greatly enhances the chance of a timely fix.
Please link to the public repository URL.
Additional context
Add any other context about the problem here.
Flutter doctor
Run flutter doctor and paste the output below:
Click To Expand
PASTE OUTPUT INSIDE HERE
Flutter dependencies
Run flutter pub deps -- --style=compact and paste the output below:
Click To Expand
PASTE OUTPUT INSIDE HERE
Metadata
Metadata
Assignees
Labels
StaleIssue with no recent activityIssue with no recent activityclosed-by-botplatform: webIssues / PRs which are specifically for web.Issues / PRs which are specifically for web.plugin: authresolution: fixedA fix has been merged or is pending merge from a PR.A fix has been merged or is pending merge from a PR.type: bugSomething isn't workingSomething isn't working