We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 724e7d9 commit 5b67c26Copy full SHA for 5b67c26
apps/dashboard/src/middleware.ts
@@ -33,7 +33,11 @@ export async function middleware(request: NextRequest) {
33
const paths = pathname.slice(1).split("/");
34
35
// nebula.thirdweb.com -> render page at app/nebula-app
36
- if (subdomain === "nebula" && host) {
+ // on vercel preview, the format is nebula---thirdweb-www-git-<branch-name>.thirdweb-preview.com
37
+ if (
38
+ subdomain &&
39
+ (subdomain === "nebula" || subdomain.startsWith("nebula---"))
40
+ ) {
41
const newPaths = ["nebula-app", ...paths];
42
return rewrite(request, `/${newPaths.join("/")}`, undefined);
43
}
0 commit comments