From b454cf6afc41a8ba012ef19bfc00ece24bcfb576 Mon Sep 17 00:00:00 2001 From: Alex Anderson Date: Thu, 27 Aug 2020 12:22:45 +0000 Subject: [PATCH] Bump eslint version, fix rules & violations --- .eslintrc | 2 +- helpers/private/connection/spawn-connection.js | 4 ++-- lib/private/redact-passwords.js | 2 +- package.json | 2 +- test/.eslintrc | 2 +- test/support/bootstrap.js | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.eslintrc b/.eslintrc index 8a1af37..f18f0ea 100644 --- a/.eslintrc +++ b/.eslintrc @@ -12,7 +12,7 @@ "eqeqeq": [1, "smart"], "eol-last": [2], "handle-callback-err": [2], - "indent": [2, 2, {"SwitchCase": 1}], + "indent": [2, 2, {"SwitchCase": 1, "MemberExpression": 0, "CallExpression": {"arguments": 0}}], "linebreak-style": [2, "unix"], "no-mixed-spaces-and-tabs": [2, "smart-tabs"], "no-return-assign": [2, "always"], diff --git a/helpers/private/connection/spawn-connection.js b/helpers/private/connection/spawn-connection.js index 3276af3..53a028a 100644 --- a/helpers/private/connection/spawn-connection.js +++ b/helpers/private/connection/spawn-connection.js @@ -54,8 +54,8 @@ module.exports = function spawnConnection(datastore, cb) { if (usingLocalhost) { console.error( - ' -> You appear to be trying to use a Postgresql install on localhost.', - 'Maybe the database server isn\'t running, or is not installed?' + ' -> You appear to be trying to use a Postgresql install on localhost.', + 'Maybe the database server isn\'t running, or is not installed?' ); console.error(''); } diff --git a/lib/private/redact-passwords.js b/lib/private/redact-passwords.js index cffa70d..bea7c77 100644 --- a/lib/private/redact-passwords.js +++ b/lib/private/redact-passwords.js @@ -28,4 +28,4 @@ module.exports = function redactPasswords(err) { } } return err; -} +}; diff --git a/package.json b/package.json index b1e4380..7072189 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ }, "devDependencies": { "benchmark": "2.1.1", - "eslint": "3.5.0", + "eslint": "7.7.0", "mocha": "3.0.2", "waterline-adapter-tests": "^1.0.0-2" }, diff --git a/test/.eslintrc b/test/.eslintrc index 2fcfa51..4a2d570 100644 --- a/test/.eslintrc +++ b/test/.eslintrc @@ -21,7 +21,7 @@ "eqeqeq": [1, "smart"], "func-style": [2, "expression"], "handle-callback-err": [2], - "indent": [2, 2, {"SwitchCase": 1}], + "indent": [2, 2, {"SwitchCase": 1, "MemberExpression": 0}], "key-spacing": [2, {"beforeColon": false, "afterColon": true}], "keyword-spacing": [2, {"before": true, "after": true}], "linebreak-style": [2, "unix"], diff --git a/test/support/bootstrap.js b/test/support/bootstrap.js index 1cd50e0..f4cf7bf 100644 --- a/test/support/bootstrap.js +++ b/test/support/bootstrap.js @@ -136,7 +136,7 @@ Support.Teardown = function teardown(tableName, cb) { return cb(err); } - var query = 'DROP TABLE IF EXISTS \"' + tableName + '";'; + var query = 'DROP TABLE IF EXISTS "' + tableName + '";'; PG.sendNativeQuery({ connection: report.connection, nativeQuery: query