[PR #4237] [MERGED] fix(db-adapter): string[] and number[] fieldTypes incorrectly parsed for plugins #13517

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

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/4237
Author: @dvanmali
Created: 8/26/2025
Status: Merged
Merged: 12/2/2025
Merged by: @himself65

Base: canaryHead: fieldTypes


📝 Commits (1)

  • 631b74c feat: add json, string[], and number[] support

📊 Changes

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

View changed files

📝 packages/better-auth/src/adapters/adapter-factory/index.ts (+13 -0)
📝 packages/better-auth/src/adapters/adapter-factory/test/adapter-factory.test.ts (+76 -0)

📄 Description

string[] and number[] field types were not converting properly for adapters, the result was still a string that needed to be JSON parsed.

Breaking Changes
Custom Plugins with utilized string[] or number[] schema field types should no longer be parsed inside the plugin.


🔄 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/4237 **Author:** [@dvanmali](https://github.com/dvanmali) **Created:** 8/26/2025 **Status:** ✅ Merged **Merged:** 12/2/2025 **Merged by:** [@himself65](https://github.com/himself65) **Base:** `canary` ← **Head:** `fieldTypes` --- ### 📝 Commits (1) - [`631b74c`](https://github.com/better-auth/better-auth/commit/631b74cdf62650c4fad311fc5439c77c697272c7) feat: add json, string[], and number[] support ### 📊 Changes **2 files changed** (+89 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/adapters/adapter-factory/index.ts` (+13 -0) 📝 `packages/better-auth/src/adapters/adapter-factory/test/adapter-factory.test.ts` (+76 -0) </details> ### 📄 Description `string[]` and `number[]` field types were not converting properly for adapters, the result was still a string that needed to be JSON parsed. **Breaking Changes** Custom Plugins with utilized `string[]` or `number[]` schema field types should no longer be parsed inside the plugin. --- <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:58:58 -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#13517