[Status Page] Improved entry page

This commit is contained in:
Louis Lam
2022-03-17 22:44:47 +08:00
parent 502c7f87e7
commit 719a136d1e
4 changed files with 34 additions and 19 deletions

View File

@@ -201,8 +201,8 @@ exports.entryPage = "dashboard";
// Entry Page
app.get("/", async (_request, response) => {
if (exports.entryPage === "statusPage") {
response.redirect("/status");
if (exports.entryPage && exports.entryPage.startsWith("statusPage-")) {
response.redirect("/status/" + exports.entryPage.replace("statusPage-", ""));
} else {
response.redirect("/dashboard");
}