From 74c31b4b6cc39d1d3d21cd6dbb1adde8d4ad7513 Mon Sep 17 00:00:00 2001 From: aniket-engg Date: Fri, 2 Oct 2020 15:07:27 +0530 Subject: [PATCH] linting fix --- libs/remix-astwalker/src/astWalker.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libs/remix-astwalker/src/astWalker.ts b/libs/remix-astwalker/src/astWalker.ts index e26445ff89..0da490a5dc 100644 --- a/libs/remix-astwalker/src/astWalker.ts +++ b/libs/remix-astwalker/src/astWalker.ts @@ -64,15 +64,15 @@ export class AstWalker extends EventEmitter { nodes = nodes.filter(e => e) // If any element in nodes is array, extract its members - let objNodes = [] + const objNodes = [] nodes.forEach(x => { if (Array.isArray(x)) objNodes.push(...x) else objNodes.push(x) }); // Filter duplicate nodes using id field - let normalizedNodes = [] - objNodes.forEach((element, index) => { + const normalizedNodes = [] + objNodes.forEach((element) => { const firstIndex = normalizedNodes.findIndex(e => e.id === element.id) if(firstIndex == -1) normalizedNodes.push(element) })