diff --git a/frontend/src/components/admin/configuration/AdminConfigTable.tsx b/frontend/src/components/admin/configuration/AdminConfigTable.tsx index 7d59af18..1a2acced 100644 --- a/frontend/src/components/admin/configuration/AdminConfigTable.tsx +++ b/frontend/src/components/admin/configuration/AdminConfigTable.tsx @@ -76,7 +76,7 @@ const AdminConfigTable = () => { .updateMany(updatedConfigVariables) .then(async () => { await configService.finishSetup(); - router.replace("/upload"); + router.reload(); }) .catch(toast.axiosError); } else { diff --git a/frontend/src/middleware.ts b/frontend/src/middleware.ts index 4d163a12..844c3025 100644 --- a/frontend/src/middleware.ts +++ b/frontend/src/middleware.ts @@ -57,6 +57,10 @@ export async function middleware(request: NextRequest) { routes.disabled.routes.push("/auth/resetPassword*"); } + if (getConfig("SETUP_STATUS") == "FINISHED") { + routes.disabled.routes.push("/admin/setup"); + } + // prettier-ignore const rules = [ // Disabled routes