From 1b0f19b019060730fcc54caa1a5e7595eef7bb4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hu=C3=A1ng=20J=C3=B9nli=C3=A0ng?= Date: Wed, 19 Aug 2020 15:35:27 -0400 Subject: [PATCH] fix: do not mutate newTypes (#11978) --- eslint/babel-eslint-parser/src/visitor-keys.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eslint/babel-eslint-parser/src/visitor-keys.js b/eslint/babel-eslint-parser/src/visitor-keys.js index 9cc7f0c315..abf0c1b515 100644 --- a/eslint/babel-eslint-parser/src/visitor-keys.js +++ b/eslint/babel-eslint-parser/src/visitor-keys.js @@ -19,4 +19,4 @@ export const conflictTypes = { ExportAllDeclaration: ESLINT_VISITOR_KEYS.ExportAllDeclaration, }; -export default Object.assign(newTypes, t.VISITOR_KEYS, conflictTypes); +export default { ...newTypes, ...t.VISITOR_KEYS, ...conflictTypes };