[PR #925] [MERGED] fix: redirect URL preventing document flow #1254

Closed
opened 2026-02-26 19:32:29 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/documenso/documenso/pull/925
Author: @dguyen
Created: 2/12/2024
Status: Merged
Merged: 2/12/2024
Merged by: @dguyen

Base: mainHead: fix/document-redirect-url


📝 Commits (2)

  • 6405f0f fix: redirect URL preventing document flow
  • c976129 fix: revert URL regex

📊 Changes

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

View changed files

📝 packages/trpc/server/document-router/schema.ts (+1 -1)
📝 packages/ui/primitives/document-flow/add-subject.types.ts (+1 -1)

📄 Description

Description

Currently the document redirect URL feature is preventing documents from being created unless a redirect URL is provided.

During the document edit flow, the redirect URL is hidden in an advanced tab with the value of an empty string, which will always fail the current Zod validation since optional requires undefined to pass.

There are multiple ways to fix this, but I think this is the easiest method where we can assume an empty string is valid.

Testing Performed

Will require retesting the feature since I'm just assuming an empty string won't break anything downstream for the redirect URL feature.

Pinging @adithyaakrishna to retest the feature.


🔄 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/documenso/documenso/pull/925 **Author:** [@dguyen](https://github.com/dguyen) **Created:** 2/12/2024 **Status:** ✅ Merged **Merged:** 2/12/2024 **Merged by:** [@dguyen](https://github.com/dguyen) **Base:** `main` ← **Head:** `fix/document-redirect-url` --- ### 📝 Commits (2) - [`6405f0f`](https://github.com/documenso/documenso/commit/6405f0fc0e4f61c761d28868e12dba7655f7b716) fix: redirect URL preventing document flow - [`c976129`](https://github.com/documenso/documenso/commit/c97612996d3b5aad3cc629ff41f6d0479a2eace0) fix: revert URL regex ### 📊 Changes **2 files changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `packages/trpc/server/document-router/schema.ts` (+1 -1) 📝 `packages/ui/primitives/document-flow/add-subject.types.ts` (+1 -1) </details> ### 📄 Description ## Description Currently the document redirect URL feature is preventing documents from being created unless a redirect URL is provided. During the document edit flow, the redirect URL is hidden in an advanced tab with the value of an empty string, which will always fail the current Zod validation since `optional` requires undefined to pass. There are multiple ways to fix this, but I think this is the easiest method where we can assume an empty string is valid. ## Testing Performed Will require retesting the feature since I'm just assuming an empty string won't break anything downstream for the redirect URL feature. Pinging @adithyaakrishna to retest the feature. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-26 19:32:29 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/documenso#1254
No description provided.