1
0
mirror of https://github.com/MisskeyIO/misskey synced 2024-11-27 22:38:30 +09:00

[Server] Fix bug

This commit is contained in:
syuilo 2017-01-21 13:20:32 +09:00
parent 42268f0fd4
commit 21d6f305c7

View File

@ -29,7 +29,7 @@ app.use(compression());
app.use((req, res, next) => {
res.header('X-Frame-Options', 'DENY');
res.locals.user = (req.headers['cookie'].match(/i=(!\w+)/) || [null, null])[1];
res.locals.user = ((req.headers['cookie'] || '').match(/i=(!\w+)/) || [null, null])[1];
next();
});