[status page] create incident

This commit is contained in:
LouisLam
2021-09-16 22:48:28 +08:00
parent 8230cfe13f
commit 2955abb5d9
13 changed files with 273 additions and 60 deletions

View File

@@ -293,3 +293,9 @@ exports.allowAllOrigin = (res) => {
res.header("Access-Control-Allow-Origin", "*");
res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept");
}
exports.checkLogin = (socket) => {
if (! socket.userID) {
throw new Error("You are not logged in.");
}
}