Fix redirects in middleware

This commit is contained in:
Fergal Moran
2024-09-30 15:50:38 +01:00
parent 9475f425bb
commit 5a3e5a2c1d

View File

@@ -7,11 +7,11 @@ export const config = {
}; };
const PATTERNS: [ const PATTERNS: [
URLPattern, URLPattern,
({ pathname }: { pathname: { groups: any } }) => any, ({ pathname }: { pathname: { groups: unknown } }) => unknown,
][] = [ ][] = [
[ [
new URLPattern({ pathname: "/i/:id" }), new URLPattern({ pathname: "/i/:id" }),
({ pathname }: { pathname: { groups: any } }) => pathname.groups, ({ pathname }: { pathname: { groups: unknown } }) => pathname.groups,
], ],
]; ];