Skip to content
This repository was archived by the owner on Oct 10, 2025. It is now read-only.

Conversation

@kangmingtay
Copy link
Member

What kind of change does this PR introduce?

  • When using the PKCE flow, if there's a redirect error after the callback and a code is not returned, getSessionFromUrl ends up returning Not a valid PKCE flow url. instead of the actual error

@kangmingtay kangmingtay force-pushed the km/fix-identity-linking-error branch from ab7630f to 59df040 Compare December 12, 2024 08:04
@kangmingtay kangmingtay merged commit 9f32d30 into master Dec 12, 2024
3 checks passed
@kangmingtay kangmingtay deleted the km/fix-identity-linking-error branch December 12, 2024 09:04
@ChuckJonas
Copy link

@kangmingtay just wanted to make sure you are aware this change causes the JWT to be nuked from local storage every time the client is loaded (when there is no session in the URL).

#1334

hf added a commit that referenced this pull request Dec 13, 2024
This reverts commit 089c687.
hf added a commit that referenced this pull request Dec 13, 2024
hf pushed a commit that referenced this pull request Dec 13, 2024
🤖 I have created a release *beep* *boop*
---


##
[2.67.1](v2.67.0...v2.67.1)
(2024-12-13)


### Bug Fixes

* revert [#992](#992) and
[#993](#993)
([#999](#999))
([12b2848](12b2848))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
kangmingtay added a commit that referenced this pull request Dec 16, 2024
kangmingtay added a commit that referenced this pull request Dec 17, 2024
## What kind of change does this PR introduce?
* Fixes the bug introduced previously in
https://github.com/supabase/auth-js/pull/993/files#diff-3522461172efd6058d6b8da62fc2d30d8b524d2b64894ea2c67218c52f7fdff5R310,
where it attempted to always try to find a session in the URL, which led
to users being logged out on a page refresh
* This PR also reverts the previous PR #992, which returns the error
early if there's a redirect, since some redirect errors (like identity
linking) should not result in the existing session being removed.
* Tested the following scenarios:
  * Sign in and refresh the page
  * Sign in and attempt to link an already existing identity
  * Sign in and attempt to link a new identity
mandarini pushed a commit to supabase/supabase-js that referenced this pull request Oct 2, 2025
🤖 I have created a release *beep* *boop*
---


##
[2.67.1](supabase/auth-js@v2.67.0...v2.67.1)
(2024-12-13)


### Bug Fixes

* revert [#992](supabase/auth-js#992) and
[#993](supabase/auth-js#993)
([#999](supabase/auth-js#999))
([03a2b5c](supabase/auth-js@03a2b5c))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants