From 81259c9bc7a3d0c34987c5c1ede379c08743eb34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bjo=CC=88rn=20Dahlgren?= Date: Sat, 15 Dec 2018 14:27:07 +0100 Subject: [PATCH] Update standard to v12 --- package.json | 2 +- routes/missions.js | 6 +++--- routes/servers.js | 6 +++--- test/lib/server.js | 4 ++-- webpack.config.js | 20 ++++++++++---------- 5 files changed, 19 insertions(+), 19 deletions(-) diff --git a/package.json b/package.json index b716792..70ab716 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,7 @@ "devDependencies": { "mocha": "~3.2.0", "should": "~13.0.1", - "standard": "^10.0.3", + "standard": "^12.0.1", "timekeeper": "0.0.5" } } diff --git a/routes/missions.js b/routes/missions.js index c8eeba1..46027b5 100644 --- a/routes/missions.js +++ b/routes/missions.js @@ -28,7 +28,7 @@ module.exports = function (missionsManager) { if (err) { res.status(500).send(err) } else { - res.status(200).json({success: true}) + res.status(200).json({ success: true }) } } ) @@ -47,7 +47,7 @@ module.exports = function (missionsManager) { if (err) { res.status(500).send(err) } else { - res.json({success: true}) + res.json({ success: true }) } }) }) @@ -64,7 +64,7 @@ module.exports = function (missionsManager) { if (err) { res.status(500).send(err) } else { - res.json({success: true}) + res.json({ success: true }) } }) }) diff --git a/routes/servers.js b/routes/servers.js index 2e6b4da..c63aa6f 100644 --- a/routes/servers.js +++ b/routes/servers.js @@ -32,16 +32,16 @@ module.exports = function (manager, mods) { router.post('/:server/start', function (req, res) { var server = manager.getServer(req.params.server) server.start() - res.json({status: 'ok', pid: server.pid}) + res.json({ status: 'ok', pid: server.pid }) }) router.post('/:server/stop', function (req, res) { var server = manager.getServer(req.params.server) server.stop(function () { if (!server.pid) { - res.json({status: true, pid: server.pid}) + res.json({ status: true, pid: server.pid }) } else { - res.json({status: false, pid: server.pid}) + res.json({ status: false, pid: server.pid }) } }) }) diff --git a/test/lib/server.js b/test/lib/server.js index 2d82043..3dfa552 100644 --- a/test/lib/server.js +++ b/test/lib/server.js @@ -5,14 +5,14 @@ var Server = require('../../lib/server.js') describe('Server', function () { describe('generateId()', function () { it('should include title', function () { - var server = new Server(null, null, {title: 'title.with.lot.of.dots'}) + var server = new Server(null, null, { title: 'title.with.lot.of.dots' }) server.generateId().should.eql('title-with-lot-of-dots') }) }) describe('toJSON()', function () { it('should include title', function () { - var server = new Server(null, null, {title: 'test'}) + var server = new Server(null, null, { title: 'test' }) server.toJSON().should.have.property('title', 'test') }) }) diff --git a/webpack.config.js b/webpack.config.js index ef361b7..45a994d 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -42,16 +42,16 @@ module.exports = { module: { loaders: [ - {test: /\.css$/, loaders: ['style-loader', 'css-loader']}, - {test: /\.json$/, loaders: ['json-loader']}, - {test: /\.png$/, loader: 'url-loader?limit=8192&mimetype=image/png'}, - {test: /\.jpe?g$/, loader: 'url-loader?limit=8192&mimetype=image/jpg'}, - {test: /\.gif$/, loader: 'url-loader?limit=8192&mimetype=image/gif'}, - {test: /\.svg(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=image/svg+xml'}, - {test: /\.woff2(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff2'}, - {test: /\.woff(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff'}, - {test: /\.ttf(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/octet-stream'}, - {test: /\.eot(\?v=\d+\.\d+\.\d+)?$/, loader: 'file-loader'} + { test: /\.css$/, loaders: ['style-loader', 'css-loader'] }, + { test: /\.json$/, loaders: ['json-loader'] }, + { test: /\.png$/, loader: 'url-loader?limit=8192&mimetype=image/png' }, + { test: /\.jpe?g$/, loader: 'url-loader?limit=8192&mimetype=image/jpg' }, + { test: /\.gif$/, loader: 'url-loader?limit=8192&mimetype=image/gif' }, + { test: /\.svg(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=image/svg+xml' }, + { test: /\.woff2(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff2' }, + { test: /\.woff(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff' }, + { test: /\.ttf(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/octet-stream' }, + { test: /\.eot(\?v=\d+\.\d+\.\d+)?$/, loader: 'file-loader' } ] },