From e02de384bd27c6131c516e05d6499845a6793707 Mon Sep 17 00:00:00 2001 From: Douglas Christopher Wilson Date: Mon, 10 Sep 2018 20:46:12 -0400 Subject: [PATCH] lint: apply standard 12 style --- .travis.yml | 2 +- README.md | 8 ++++---- package.json | 12 ++++++------ test/morgan.js | 6 +++--- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index 11a3951..d1ffba5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -21,7 +21,7 @@ before_install: - "npm config set shrinkwrap false" # Setup Node.js version-specific dependencies - "test $TRAVIS_NODE_VERSION != '0.8' || npm rm --save-dev istanbul" - - "test $(echo $TRAVIS_NODE_VERSION | cut -d. -f1) -ge 4 || npm rm --save-dev $(grep -E '\"eslint\\S*\"' package.json | cut -d'\"' -f2)" + - "test $(echo $TRAVIS_NODE_VERSION | cut -d. -f1) -ge 6 || npm rm --save-dev $(grep -E '\"eslint\\S*\"' package.json | cut -d'\"' -f2)" # Update Node.js modules - "test ! -d node_modules || npm prune" - "test ! -d node_modules || npm rebuild" diff --git a/README.md b/README.md index 9cb6fc4..ba8b256 100644 --- a/README.md +++ b/README.md @@ -294,10 +294,10 @@ var path = require('path') var app = express() // create a write stream (in append mode) -var accessLogStream = fs.createWriteStream(path.join(__dirname, 'access.log'), {flags: 'a'}) +var accessLogStream = fs.createWriteStream(path.join(__dirname, 'access.log'), { flags: 'a' }) // setup the logger -app.use(morgan('combined', {stream: accessLogStream})) +app.use(morgan('combined', { stream: accessLogStream })) app.get('/', function (req, res) { res.send('hello, world!') @@ -330,7 +330,7 @@ var accessLogStream = rfs('access.log', { }) // setup the logger -app.use(morgan('combined', {stream: accessLogStream})) +app.use(morgan('combined', { stream: accessLogStream })) app.get('/', function (req, res) { res.send('hello, world!') @@ -364,7 +364,7 @@ app.use(morgan('dev', { // log all requests to access.log app.use(morgan('common', { - stream: fs.createWriteStream(path.join(__dirname, 'access.log'), {flags: 'a'}) + stream: fs.createWriteStream(path.join(__dirname, 'access.log'), { flags: 'a' }) })) app.get('/', function (req, res) { diff --git a/package.json b/package.json index b2e4162..077e13a 100644 --- a/package.json +++ b/package.json @@ -22,13 +22,13 @@ "on-headers": "~1.0.1" }, "devDependencies": { - "eslint": "4.19.1", - "eslint-config-standard": "11.0.0", - "eslint-plugin-import": "2.12.0", + "eslint": "5.5.0", + "eslint-config-standard": "12.0.0", + "eslint-plugin-import": "2.14.0", "eslint-plugin-markdown": "1.0.0-beta.6", - "eslint-plugin-node": "6.0.1", - "eslint-plugin-promise": "3.8.0", - "eslint-plugin-standard": "3.1.0", + "eslint-plugin-node": "7.0.1", + "eslint-plugin-promise": "4.0.1", + "eslint-plugin-standard": "4.0.0", "istanbul": "0.4.5", "mocha": "2.5.3", "split": "1.0.1", diff --git a/test/morgan.js b/test/morgan.js index ff50b49..a2432e7 100644 --- a/test/morgan.js +++ b/test/morgan.js @@ -439,7 +439,7 @@ describe('morgan()', function () { }) }) - var agent = new https.Agent({ca: cert}) + var agent = new https.Agent({ ca: cert }) var createConnection = agent.createConnection agent.createConnection = function (options) { @@ -1226,7 +1226,7 @@ describe('morgan()', function () { }) var server = createServer(':method :url', { buffer: true, - stream: {write: writeLog} + stream: { write: writeLog } }) var time = Date.now() @@ -1254,7 +1254,7 @@ describe('morgan()', function () { }) var server = createServer(':method :url', { buffer: 200, - stream: {write: writeLog} + stream: { write: writeLog } }) var time = Date.now()