[PR #3830] [CLOSED] fix: secondary storage session deletion #21933

Closed
opened 2026-04-15 20:42:18 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/3830
Author: @dvanmali
Created: 8/6/2025
Status: Closed

Base: mainHead: internalAdapter


📝 Commits (10+)

  • af239b7 chore: remove changeset and add contributing code of conduct
  • d313d00 fix: await ctx in middleware (#3783)
  • b71e8a7 Merge branch 'main' into canary
  • ca3a134 chore: remove changeset
  • ee63084 chore: remove changeset ci
  • 3266232 fix: plugins options type compatibility issue with exactOptionalPropertyTypes enabled in ts-config (#3769)
  • 5eca938 feat(organization): add option for requiring email verificaiton (#3785)
  • 575070f chore: bump biome (#3784)
  • e57a49f chore: release v1.3.5-beta.2
  • f04570a chore: bump vitest version (#3810)

📊 Changes

100 files changed (+1233 additions, -1404 deletions)

View changed files

.changeset/README.md (+0 -8)
.changeset/angry-items-boil.md (+0 -5)
.changeset/breezy-rice-grin.md (+0 -5)
.changeset/config.json (+0 -27)
.changeset/curly-kids-film.md (+0 -5)
.changeset/fast-suns-peel.md (+0 -5)
.changeset/funny-rules-rest.md (+0 -5)
.changeset/huge-needles-smell.md (+0 -5)
.changeset/mighty-tables-dream.md (+0 -5)
.changeset/olive-toys-pump.md (+0 -5)
.changeset/open-guests-stare.md (+0 -2)
.changeset/salty-banks-heal.md (+0 -5)
.changeset/silly-falcons-tie.md (+0 -5)
.changeset/slimy-paws-sin.md (+0 -5)
.changeset/soft-pugs-flash.md (+0 -5)
.changeset/stale-tomatoes-warn.md (+0 -5)
.changeset/strong-points-admire.md (+0 -5)
.changeset/tasty-teachers-compete.md (+0 -5)
.changeset/twenty-camels-float.md (+0 -5)
.github/changeset-version.js (+0 -11)

...and 80 more files

📄 Description

Deletion of a session removed its token-based secondary storage but left a hanging token in the user-based secondary storage.

Fix: deletion of session also removes token on user-based secondary storage.


Summary by cubic

Fixed session deletion so that tokens are now removed from both token-based and user-based secondary storage, preventing leftover tokens after a session is deleted.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/3830 **Author:** [@dvanmali](https://github.com/dvanmali) **Created:** 8/6/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `internalAdapter` --- ### 📝 Commits (10+) - [`af239b7`](https://github.com/better-auth/better-auth/commit/af239b78794912316545d8d80b372e67beacb276) chore: remove changeset and add contributing code of conduct - [`d313d00`](https://github.com/better-auth/better-auth/commit/d313d0093e97dea57879be9dfd43143275380010) fix: await `ctx` in middleware (#3783) - [`b71e8a7`](https://github.com/better-auth/better-auth/commit/b71e8a7ec004a80c0b6cf7ef3f5041b92df5bdcf) Merge branch 'main' into canary - [`ca3a134`](https://github.com/better-auth/better-auth/commit/ca3a13407e0d94e3dfec14821b4e43777d8e59f8) chore: remove changeset - [`ee63084`](https://github.com/better-auth/better-auth/commit/ee63084a2e2551d6527d0d1b931c2eb2e70f46e4) chore: remove changeset ci - [`3266232`](https://github.com/better-auth/better-auth/commit/32662322013230a271e43793270407d021030a3f) fix: plugins options type compatibility issue with `exactOptionalPropertyTypes` enabled in ts-config (#3769) - [`5eca938`](https://github.com/better-auth/better-auth/commit/5eca9389338a900149786bb09b4d802a80e4c668) feat(organization): add option for requiring email verificaiton (#3785) - [`575070f`](https://github.com/better-auth/better-auth/commit/575070f6057851be2d976d02dd3c9a3498044c32) chore: bump `biome` (#3784) - [`e57a49f`](https://github.com/better-auth/better-auth/commit/e57a49f99dbf72d462d94e8f8ccaec747eb1a725) chore: release v1.3.5-beta.2 - [`f04570a`](https://github.com/better-auth/better-auth/commit/f04570a6d8cac4505b1b9799e67bfab2f60b0b2e) chore: bump vitest version (#3810) ### 📊 Changes **100 files changed** (+1233 additions, -1404 deletions) <details> <summary>View changed files</summary> ➖ `.changeset/README.md` (+0 -8) ➖ `.changeset/angry-items-boil.md` (+0 -5) ➖ `.changeset/breezy-rice-grin.md` (+0 -5) ➖ `.changeset/config.json` (+0 -27) ➖ `.changeset/curly-kids-film.md` (+0 -5) ➖ `.changeset/fast-suns-peel.md` (+0 -5) ➖ `.changeset/funny-rules-rest.md` (+0 -5) ➖ `.changeset/huge-needles-smell.md` (+0 -5) ➖ `.changeset/mighty-tables-dream.md` (+0 -5) ➖ `.changeset/olive-toys-pump.md` (+0 -5) ➖ `.changeset/open-guests-stare.md` (+0 -2) ➖ `.changeset/salty-banks-heal.md` (+0 -5) ➖ `.changeset/silly-falcons-tie.md` (+0 -5) ➖ `.changeset/slimy-paws-sin.md` (+0 -5) ➖ `.changeset/soft-pugs-flash.md` (+0 -5) ➖ `.changeset/stale-tomatoes-warn.md` (+0 -5) ➖ `.changeset/strong-points-admire.md` (+0 -5) ➖ `.changeset/tasty-teachers-compete.md` (+0 -5) ➖ `.changeset/twenty-camels-float.md` (+0 -5) ➖ `.github/changeset-version.js` (+0 -11) _...and 80 more files_ </details> ### 📄 Description Deletion of a session removed its token-based secondary storage but left a hanging token in the user-based secondary storage. Fix: deletion of session also removes token on user-based secondary storage. <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Fixed session deletion so that tokens are now removed from both token-based and user-based secondary storage, preventing leftover tokens after a session is deleted. <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 20:42:18 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#21933