Fix invalid cookie names

This commit is contained in:
zkldi
2021-11-05 19:21:33 +00:00
parent 7b598bfa18
commit 77c533b38d
+1 -1
View File
@@ -27,7 +27,7 @@ const userSessionMiddleware = expressSession({
// append node_env onto the end of the session name
// so we can separate tokens under the same URL.
// say for staging.kamaitachi.xyz
name: `${TachiConfig.NAME} (${Environment.nodeEnv}) SESSION`,
name: `${TachiConfig.NAME.replace(/ /gu, "_")}_SESSION`,
secret: ServerConfig.SESSION_SECRET,
store,
resave: true,