Merge branch 'julius-dev' of Software_Engineering_I/greenvironment-server into develop

pull/2/head
Trivernis 5 years ago committed by Gitea
commit e80bab131e

@ -87,8 +87,14 @@ export function resolver(req: any, res: any): any {
} }
}, },
logout() { logout() {
if (req.session.user) { if (req.session.userId) {
delete req.session.user; delete req.session.userId;
req.session.save((err: any) => {
if (err) {
globals.logger.error(err.message);
globals.logger.debug(err.stack);
}
});
return true; return true;
} else { } else {
res.status(status.UNAUTHORIZED); res.status(status.UNAUTHORIZED);

@ -52,6 +52,7 @@ namespace globals {
}), }),
), ),
json: false, json: false,
level: config.logging.level,
maxFiles: "7d", maxFiles: "7d",
zippedArchive: true, zippedArchive: true,
}), }),

Loading…
Cancel
Save