diff --git a/.eslintrc b/.eslintrc index 51a7893..8a5a28b 100644 --- a/.eslintrc +++ b/.eslintrc @@ -3,7 +3,7 @@ "node": true }, "rules": { - "indent": [2, 2], - "quotes": "single" + "indent": ["error", 2, { "SwitchCase": 1 }], + "quotes": ["error", "single"] } } diff --git a/lib/index.js b/lib/index.js index 013469c..79c7ca2 100644 --- a/lib/index.js +++ b/lib/index.js @@ -6,11 +6,11 @@ var vary = require('vary'); var defaults = { - origin: '*', - methods: 'GET,HEAD,PUT,PATCH,POST,DELETE', - preflightContinue: false, - optionsSuccessStatus: 204 - }; + origin: '*', + methods: 'GET,HEAD,PUT,PATCH,POST,DELETE', + preflightContinue: false, + optionsSuccessStatus: 204 + }; function isString(s) { return typeof s === 'string' || s instanceof String; diff --git a/package.json b/package.json index 408267d..71c7555 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,7 @@ "devDependencies": { "basic-auth-connect": "^1.0.0", "body-parser": "^1.12.4", - "eslint": "^0.21.2", + "eslint": "2.13.1", "express": "^4.12.4", "istanbul": "^0.4.5", "mocha": "3.4.2", diff --git a/test/.eslintrc b/test/.eslintrc new file mode 100644 index 0000000..7eeefc3 --- /dev/null +++ b/test/.eslintrc @@ -0,0 +1,5 @@ +{ + "env": { + "mocha": true + } +} diff --git a/test/basic-auth.js b/test/basic-auth.js index 1323f42..3a552a3 100644 --- a/test/basic-auth.js +++ b/test/basic-auth.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/body-events.js b/test/body-events.js index 99d582b..f35489f 100644 --- a/test/body-events.js +++ b/test/body-events.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/cors.js b/test/cors.js index 755f685..1f98317 100644 --- a/test/cors.js +++ b/test/cors.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/error-response.js b/test/error-response.js index 06c7b97..c887f8f 100644 --- a/test/error-response.js +++ b/test/error-response.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/example-app.js b/test/example-app.js index 590cb31..cec5204 100644 --- a/test/example-app.js +++ b/test/example-app.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/issue-2.js b/test/issue-2.js index 0784bcd..e52db95 100644 --- a/test/issue-2.js +++ b/test/issue-2.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict'; diff --git a/test/issue-31.js b/test/issue-31.js index 4f678fe..578033b 100644 --- a/test/issue-31.js +++ b/test/issue-31.js @@ -1,5 +1,4 @@ (function () { - /*global describe, it*/ 'use strict';