From 5315dd95b0402b656d07660b705b27a0404183d4 Mon Sep 17 00:00:00 2001 From: "Alex Lam S.L" Date: Sat, 15 Feb 2020 17:55:26 +0000 Subject: [PATCH] minor cleanup (#3723) --- lib/ast.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/ast.js b/lib/ast.js index 99e2353e44..a3b802149b 100644 --- a/lib/ast.js +++ b/lib/ast.js @@ -169,10 +169,7 @@ var AST_SimpleStatement = DEFNODE("SimpleStatement", "body", { }, AST_Statement); function walk_body(node, visitor) { - var body = node.body; - if (body instanceof AST_Statement) { - body._walk(visitor); - } else body.forEach(function(node) { + node.body.forEach(function(node) { node._walk(visitor); }); }