Skip to content
This repository was archived by the owner on Mar 17, 2026. It is now read-only.

Commit 520aed2

Browse files
fix(middleware): avoid double slash in /flashblocks redirect (#2974)
1 parent 82b0f0a commit 520aed2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

apps/web/middleware.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export function middleware(req: NextRequest) {
1414
if (url.pathname.startsWith('/flashblocks')) {
1515
const subPath = url.pathname.replace('/flashblocks', '');
1616
url.host = 'flashblocks.base.org';
17-
url.pathname = `/${subPath}`;
17+
url.pathname = subPath.startsWith('/') ? subPath : `/${subPath}`;
1818
url.port = '443';
1919

2020
return NextResponse.redirect(url);

0 commit comments

Comments
 (0)