Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.
fix: middleware for custom domains
Marc Seitz0ff6ac6ce593
diff --git a/lib/middleware/domain.ts b/lib/middleware/domain.tsindex 07da83a3..68b0f695 100644--- a/lib/middleware/domain.ts+++ b/lib/middleware/domain.ts@@ -23,7 +23,7 @@ export default async function DomainMiddleware(req: NextRequest) {// Rewrite the URL to the correct page component for custom domains// Rewrite to the pages/view/domains/[domain]/[slug] route- url.pathname = `/view/domains/${host}/${path}`;+ url.pathname = `/view/domains/${host}${path}`;return NextResponse.rewrite(url, {headers: {