From: Alex Lam S.L Date: Sat, 15 Feb 2020 17:55:26 +0000 (+0000) Subject: minor cleanup (#3723) X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=5315dd95b0402b656d07660b705b27a0404183d4;p=UglifyJS.git minor cleanup (#3723) --- diff --git a/lib/ast.js b/lib/ast.js index 99e2353e..a3b80214 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); }); }