[PR #2812] [CLOSED] feat: Support DB hooks for all models #4499

Closed
opened 2026-03-13 11:49:11 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/2812
Author: @ping-maxwell
Created: 5/28/2025
Status: Closed

Base: mainHead: feat/db-hooks-supports-any-table


📝 Commits (3)

  • ed6df1d feat: Support DB hooks for all models
  • db25260 fix: forceAllowId bugs
  • 7b8b897 chore: remove debug logs

📊 Changes

1 file changed (+104 additions, -31 deletions)

View changed files

📝 packages/better-auth/src/adapters/create-adapter/index.ts (+104 -31)

📄 Description

Currently we only support DB hooks on 4 built in tables. This will allow support for any table.

This PR must be merged alongside my other PR which introduces types for database hooks.
https://github.com/better-auth/better-auth/pull/2158


🔄 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/2812 **Author:** [@ping-maxwell](https://github.com/ping-maxwell) **Created:** 5/28/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feat/db-hooks-supports-any-table` --- ### 📝 Commits (3) - [`ed6df1d`](https://github.com/better-auth/better-auth/commit/ed6df1da5a9e5c28092ef76d5ed5c25ee9f93bdf) feat: Support DB hooks for all models - [`db25260`](https://github.com/better-auth/better-auth/commit/db252600d8848f5d733a4c8e466248fadc09007b) fix: forceAllowId bugs - [`7b8b897`](https://github.com/better-auth/better-auth/commit/7b8b8977ccf666ec6d3f84526a238f007d74af2d) chore: remove debug logs ### 📊 Changes **1 file changed** (+104 additions, -31 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/adapters/create-adapter/index.ts` (+104 -31) </details> ### 📄 Description Currently we only support DB hooks on 4 built in tables. This will allow support for any table. This PR **must** be merged alongside my other PR which introduces types for database hooks. https://github.com/better-auth/better-auth/pull/2158 --- <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-03-13 11:49:11 -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#4499