[PR #1823] [MERGED] fix: allow plus signs in relative callback URLs #29611

Closed
opened 2026-04-17 20:54:45 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/1823
Author: @javawizard
Created: 3/14/2025
Status: Merged
Merged: 3/15/2025
Merged by: @Bekacru

Base: mainHead: jw/allow-plus-in-urls


📝 Commits (1)

  • 32f4715 fix: allow plus signs in relative callback URLs

📊 Changes

2 files changed (+20 additions, -2 deletions)

View changed files

📝 packages/better-auth/src/api/middlewares/origin-check.test.ts (+18 -0)
📝 packages/better-auth/src/api/middlewares/origin-check.ts (+2 -2)

📄 Description

new URLSearchParams(...).toString() loves to generate +s instead of %20s for spaces; this PR allows them in relative paths.


🔄 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/1823 **Author:** [@javawizard](https://github.com/javawizard) **Created:** 3/14/2025 **Status:** ✅ Merged **Merged:** 3/15/2025 **Merged by:** [@Bekacru](https://github.com/Bekacru) **Base:** `main` ← **Head:** `jw/allow-plus-in-urls` --- ### 📝 Commits (1) - [`32f4715`](https://github.com/better-auth/better-auth/commit/32f47156b29eebbcd3f0e7c1dcbb5a74516f1606) fix: allow plus signs in relative callback URLs ### 📊 Changes **2 files changed** (+20 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/api/middlewares/origin-check.test.ts` (+18 -0) 📝 `packages/better-auth/src/api/middlewares/origin-check.ts` (+2 -2) </details> ### 📄 Description `new URLSearchParams(...).toString()` loves to generate `+`s instead of `%20`s for spaces; this PR allows them in relative paths. --- <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 20:54:45 -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#29611