diff --git a/server/auth.js b/server/auth.js index 31b4f7a2..06de66fa 100644 --- a/server/auth.js +++ b/server/auth.js @@ -5,7 +5,6 @@ const auth = require('basic-auth'); * against the given credentials. */ exports.basicAuth = (username, password) => { - if (!username || !password) { throw new Error('Missing required username and password for basic authentication.'); } @@ -17,9 +16,7 @@ exports.basicAuth = (username, password) => { next(); } else { res - .set({ - 'WWW-Authenticate': 'Basic realm="Authentication required"', - }) + .set({ 'WWW-Authenticate': 'Basic realm="Authentication required"' }) .status(401) .end("I'm afraid I cannot let you do that."); } diff --git a/server/index.js b/server/index.js index 6b549783..5b486f2a 100644 --- a/server/index.js +++ b/server/index.js @@ -42,7 +42,6 @@ const indexHtml = fs.readFileSync(path.join(buildPath, 'index.html'), 'utf-8'); const reNoMatch = /($^)/; const template = _.template(indexHtml, { - // Interpolate variables in the HTML template with the following // syntax: // @@ -61,7 +60,6 @@ const template = _.template(indexHtml, { // - https://github.com/kangax/html-minifier // - Plugin options in the production Webpack configuration file interpolate: //g, - // Disable evaluated and escaped variables in the template evaluate: reNoMatch, escape: reNoMatch, @@ -69,10 +67,7 @@ const template = _.template(indexHtml, { function render(url, context) { const { head, body } = renderApp(url, context); - return template({ - title: head.title.toString(), - body - }); + return template({ title: head.title.toString(), body }); } const env = process.env.NODE_ENV; diff --git a/src/components/index.js b/src/components/index.js index afd7ef74..b7b8cfb1 100644 --- a/src/components/index.js +++ b/src/components/index.js @@ -1,5 +1,3 @@ import Page from './Page/Page'; -export { - Page -}; +export { Page }; diff --git a/src/styles/variables.js b/src/styles/variables.js index 042e279e..1b21d464 100644 --- a/src/styles/variables.js +++ b/src/styles/variables.js @@ -32,6 +32,4 @@ * Note that this file is required for the build process. */ -module.exports = { - -}; +module.exports = {};