[PR #7764] chore: expose refreshUserSessions on internal adapter #33140

Open
opened 2026-04-17 23:48:27 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/7764
Author: @programming-with-ia
Created: 2/2/2026
Status: 🔄 Open

Base: mainHead: canary


📝 Commits (2)

  • ffab34c expose refreshUserSessions on internal adapter
  • ab5932d Add refreshUserSessions to InternalAdapter interface

📊 Changes

2 files changed (+3 additions, -0 deletions)

View changed files

📝 packages/better-auth/src/db/internal-adapter.ts (+1 -0)
📝 packages/core/src/types/context.ts (+2 -0)

📄 Description

Summary by cubic

Expose refreshUserSessions(user: User): Promise<void> on the InternalAdapter interface and return it from createInternalAdapter, so apps can trigger session refresh via a stable API. Enables session rotation/invalidation without touching lower-level DB utilities.

Written for commit ab5932df80. Summary will update on new commits.


🔄 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/7764 **Author:** [@programming-with-ia](https://github.com/programming-with-ia) **Created:** 2/2/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `canary` --- ### 📝 Commits (2) - [`ffab34c`](https://github.com/better-auth/better-auth/commit/ffab34c8c5475de2071d7747773ae258513b21b3) expose refreshUserSessions on internal adapter - [`ab5932d`](https://github.com/better-auth/better-auth/commit/ab5932df802b381914fe03603dbba097ec436f90) Add refreshUserSessions to InternalAdapter interface ### 📊 Changes **2 files changed** (+3 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/db/internal-adapter.ts` (+1 -0) 📝 `packages/core/src/types/context.ts` (+2 -0) </details> ### 📄 Description <!-- This is an auto-generated description by cubic. --> ## Summary by cubic Expose `refreshUserSessions(user: User): Promise<void>` on the `InternalAdapter` interface and return it from `createInternalAdapter`, so apps can trigger session refresh via a stable API. Enables session rotation/invalidation without touching lower-level DB utilities. <sup>Written for commit ab5932df802b381914fe03603dbba097ec436f90. Summary will update on new commits.</sup> <!-- 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-17 23:48:27 -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#33140