From e38474ce40822e67c10ed7b9d66a212724dbaf68 Mon Sep 17 00:00:00 2001 From: Cassie Tarakajian Date: Mon, 27 Nov 2017 17:32:03 -0500 Subject: [PATCH] fix linting errors --- server/controllers/embed.controller.js | 3 ++- server/server.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/server/controllers/embed.controller.js b/server/controllers/embed.controller.js index 086be56c..447527ff 100644 --- a/server/controllers/embed.controller.js +++ b/server/controllers/embed.controller.js @@ -11,7 +11,8 @@ export function serveProject(req, res) { Project.findById(req.params.project_id) .exec((err, project) => { if (err || !project) { - return get404Sketch(html => res.send(html)); + get404Sketch(html => res.send(html)); + return; } // TODO this does not parse html const files = project.files; diff --git a/server/server.js b/server/server.js index 12bb8624..e1f95165 100644 --- a/server/server.js +++ b/server/server.js @@ -132,7 +132,7 @@ app.get('*', (req, res) => { }); // error handler -app.use((err, req, res, next) => { +app.use((err, req, res, next) => { if (err.code !== 'EBADCSRFTOKEN') return next(err); console.error('Invalid CSRF Token.');