From ea5be270c87b3efa5a0e27b4f5b0153c4539aab7 Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Sun, 19 Mar 2023 11:32:45 +0200 Subject: [PATCH] index.js: use array spread instead of concat --- index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index 6d5885a..ebbf011 100644 --- a/index.js +++ b/index.js @@ -119,7 +119,10 @@ function precinct(content, options = {}) { } function detectiveEs6Cjs(ast, detectiveOptions) { - return detectiveEs6(ast, detectiveOptions).concat(detectiveCjs(ast, detectiveOptions)); + return [ + ...detectiveEs6(ast, detectiveOptions), + ...detectiveCjs(ast, detectiveOptions) + ]; } /**