Openstatus www.openstatus.dev

ok now?

+2 -2
+2 -2
apps/status-page/src/middleware.ts
··· 123 123 } 124 124 125 125 console.log({customDomain: _page.customDomain, host, expectedHost: `${_page.slug}.stpg.dev`}) 126 - if (_page.customDomain && url.host !== `${_page.slug}.stpg.dev`) { 126 + if (_page.customDomain && host !== `${_page.slug}.stpg.dev`) { 127 127 if (pathnames.length > 2 && !subdomain) { 128 128 const pathname = pathnames.slice(2).join("/"); 129 129 const rewriteUrl = new URL(`/${_page.slug}/${pathname}`, req.url); ··· 135 135 // const vercelURL = process.env.VERCEL_URL || "www.stpg.dev"; 136 136 // console.log({newUrl: vercelURL}) 137 137 if (pathnames.length > 2) { 138 - const pathname = pathnames.slice(2).join("/"); 138 + const pathname = pathnames.slice(1).join("/"); 139 139 140 140 const rewriteUrl = new URL( 141 141 `${pathname}`,