diff --git a/lib/6to5/transformation/transformers/es6/parameters.default.js b/lib/6to5/transformation/transformers/es6/parameters.default.js index c529f5a36e..00f2d47f3f 100644 --- a/lib/6to5/transformation/transformers/es6/parameters.default.js +++ b/lib/6to5/transformation/transformers/es6/parameters.default.js @@ -13,7 +13,7 @@ var hasDefaults = function (node) { var iifeVisitor = { enter: function (node, parent, scope, context, state) { - if (t.isReferencedIdentifier(node, parent) && scope.hasOwn(node.name)) { + if (t.isReferencedIdentifier(node, parent) && state.scope.hasOwn(node.name)) { state.iife = true; context.stop(); }