mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-14 17:26:26 +01:00
🐛 Issue with middleware redirect in docker
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { NextRequest, NextResponse } from 'next/server';
|
||||
import { env } from 'process';
|
||||
|
||||
import { getUrl } from './tools/server/url';
|
||||
import { client } from './utils/api';
|
||||
|
||||
const skippedUrls = [
|
||||
@@ -41,7 +42,5 @@ export async function middleware(req: NextRequest) {
|
||||
return NextResponse.next();
|
||||
}
|
||||
|
||||
url.pathname = '/onboard';
|
||||
|
||||
return NextResponse.redirect(url);
|
||||
return NextResponse.redirect(getUrl(req) + '/onboard');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user