Skip to content

docs(auth): update account-exists guidance after fetchSignInMethodsForEmail removal - #18547

Merged
Lyokone merged 1 commit into
mainfrom
docs/auth-account-exists-guidance
Aug 10, 2026
Merged

docs(auth): update account-exists guidance after fetchSignInMethodsForEmail removal#18547
Lyokone merged 1 commit into
mainfrom
docs/auth-account-exists-guidance

Conversation

@Lyokone

@Lyokone Lyokone commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Description

FirebaseAuth.fetchSignInMethodsForEmail() was removed in firebase_auth 6.0.0 (#17562, for email-enumeration security reasons), but the error-code documentation still instructs users to call it.

Existing behavior — the docs for account-exists-with-different-credential and email-already-in-use tell the reader to call fetchSignInMethodsForEmail, sign in with one of the providers it returns, and then link the original credential. That first step is no longer possible from the public API, so the recovery flow as documented cannot be followed.

This PR rewrites that guidance to the flow that still works: ask the user to sign in with a provider already linked to the email address, then link the original credential with linkWithCredential.

Two smaller cleanups from the same removal:

  • firebase_auth.dart had a stray // ignore: deprecated_member_use_from_same_package left inside the signInWithCredential doc comment. The deprecated member it suppressed is gone, and it had been dropped in mid-sentence, leaving Resolve this by asking the user to sign in using one of the returned providers with nothing returning them.
  • AuthCredential.signInMethod described itself as "the sign-in method identifier returned in fetchSignInMethodsForEmail". That trailing clause is dropped.

Six doc sites across three files, all /// comments. No API, behavior, or signature changes.

Out of scope: firebase_auth_web/lib/src/interop/auth_interop.dart still references firebase.auth.Auth.fetchSignInMethodsForEmail, but that documents the underlying JS SDK method in the interop layer rather than the Dart API, so it is left alone.

Related Issues

Fixes #12909

Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See Contributor Guide).
    • N/A — documentation-only change, no behavior to test.
  • All existing and new tests are passing.
    • Not run locally; nothing executable changed. CI to confirm.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (melos run analyze) does not report any problems on my PR.
  • I read and followed the Flutter Style Guide.
  • I signed the CLA.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

…rEmail removal

fetchSignInMethodsForEmail() was removed in firebase_auth 6.0.0, but the
error-code docs still told users to call it to resolve
account-exists-with-different-credential and email-already-in-use. Point
them at signing in with an already-linked provider and then linking the
original credential instead.

Also removes a stray '// ignore: deprecated_member_use_from_same_package'
left inside the signInWithCredential doc comment, which had split the
sentence mid-clause.

Fixes #12909
@gemini-code-assist

Copy link
Copy Markdown
Contributor
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

@Lyokone
Lyokone merged commit b0585f0 into main Aug 10, 2026
36 checks passed
@Lyokone
Lyokone deleted the docs/auth-account-exists-guidance branch August 10, 2026 07:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[📚] Flutter handle errors not up to date

3 participants