From 74703665dfefdd9ccc427457cf5ff599df5bab2b Mon Sep 17 00:00:00 2001 From: Josh Johnson Date: Tue, 15 Aug 2017 13:06:59 +0100 Subject: [PATCH] Resolve constructor issue --- .eslintrc | 3 ++- assets/scripts/src/choices.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.eslintrc b/.eslintrc index b5bd973..f15b85d 100644 --- a/.eslintrc +++ b/.eslintrc @@ -11,6 +11,7 @@ "rules": { "strict": 0, "no-underscore-dangle": 0, - "no-console": ["warn", { allow: ["warn", "error"] }] + "no-console": ["warn", { allow: ["warn", "error"] }], + "space-before-function-paren": 0 } } diff --git a/assets/scripts/src/choices.js b/assets/scripts/src/choices.js index 59a0f8a..0f67db5 100644 --- a/assets/scripts/src/choices.js +++ b/assets/scripts/src/choices.js @@ -45,7 +45,8 @@ class Choices { if (elements.length > 1) { for (let i = 1; i < elements.length; i += 1) { const el = elements[i]; - return new Choices(el, userConfig); + /* eslint-disable no-new */ + new Choices(el, userConfig); } } }