Skip to content
This repository was archived by the owner on Jan 23, 2026. It is now read-only.
This repository was archived by the owner on Jan 23, 2026. It is now read-only.

Current session lost when auth function call fails #904

Closed

Description

@bombillazo

Bug report

  • I confirm this is a bug with Supabase, not with my own application.
  • I confirm I have searched the Docs, GitHub Discussions, and Discord.

Describe the bug

Currently, the client logic calls _removeSession to clear the session when doing an auth call. If the call fails, the existing session is never restored and is lost, effectively disconnecting the user session.

To Reproduce

Steps to reproduce the behavior, please provide code snippets or a repository:

  1. Create a supabase client and log in
  2. Call an auth function with invalid parameters
  3. Get the client session

Expected behavior

The existing client session is kept in the event of a fail.

System information

  • Version of supabase-js: 2.64.2

Activity

  1. added
    bug
    on May 9, 2024
  2. bombillazo commented on Jun 18, 2024

    @bombillazo
    ContributorAuthor

    This was closed with #915

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions