[PR #2437] [MERGED] fix(create-adapter): transformWhere to account for customTransformInput #12567

Closed
opened 2026-04-13 08:28:13 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/2437
Author: @ping-maxwell
Created: 4/25/2025
Status: Merged
Merged: 6/28/2025
Merged by: @Bekacru

Base: mainHead: fix/create-adapter/where-custom-transform-input


📝 Commits (2)

  • 973d01c fix(create-adapter): transformWhere to account for customTransformInput
  • 0e63ac0 chore: lint

📊 Changes

3 files changed (+41 additions, -6 deletions)

View changed files

📝 docs/app/page.tsx (+0 -1)
📝 packages/better-auth/src/adapters/create-adapter/index.ts (+8 -4)
📝 packages/better-auth/src/adapters/create-adapter/test/create-adapter.test.ts (+33 -1)

📄 Description

The transformWhereClause function in createAdapter didn't take into account of customTransformInput.
I also think this is the reason the Mongo adapter didn't work.

Fixed this, and added tests to take into account of this.


🔄 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/2437 **Author:** [@ping-maxwell](https://github.com/ping-maxwell) **Created:** 4/25/2025 **Status:** ✅ Merged **Merged:** 6/28/2025 **Merged by:** [@Bekacru](https://github.com/Bekacru) **Base:** `main` ← **Head:** `fix/create-adapter/where-custom-transform-input` --- ### 📝 Commits (2) - [`973d01c`](https://github.com/better-auth/better-auth/commit/973d01c5eb27eee8dbfcb0138897afe100829ed4) fix(create-adapter): transformWhere to account for customTransformInput - [`0e63ac0`](https://github.com/better-auth/better-auth/commit/0e63ac0bc484df8a7153cdd66f7fef26ae726b47) chore: lint ### 📊 Changes **3 files changed** (+41 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `docs/app/page.tsx` (+0 -1) 📝 `packages/better-auth/src/adapters/create-adapter/index.ts` (+8 -4) 📝 `packages/better-auth/src/adapters/create-adapter/test/create-adapter.test.ts` (+33 -1) </details> ### 📄 Description The `transformWhereClause` function in createAdapter didn't take into account of customTransformInput. I also think this is the reason the Mongo adapter didn't work. Fixed this, and added tests to take into account of this. --- <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-13 08:28:13 -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#12567