Comparing version 3.3.2 to 3.3.3
@@ -19,4 +19,4 @@ "use strict"; | ||
exports.ThisExpression = function (node, parent, scope, context, file) { | ||
throw file.errorWithNode(node, "Top level `this` is `undefined` in strict mode", ReferenceError); | ||
exports.ThisExpression = function () { | ||
return t.identifier("undefined"); | ||
}; |
@@ -260,4 +260,5 @@ "use strict"; | ||
// yes: { [NODE]: "" } | ||
if (t.isProperty(parent)) { | ||
return parent.key === node && parent.computed; | ||
// no: { NODE: "" } | ||
if (t.isProperty(parent) && parent.key === node) { | ||
return parent.computed; | ||
} | ||
@@ -411,6 +412,7 @@ | ||
* @param {String} match Dot delimetered string | ||
* @param {Boolean} [allowPartial] Allow a partial match | ||
* @returns {Function} | ||
*/ | ||
t.buildMatchMemberExpression = function (match) { | ||
t.buildMatchMemberExpression = function (match, allowPartial) { | ||
var parts = match.split("."); | ||
@@ -450,3 +452,7 @@ | ||
if (++i > parts.length) { | ||
return false; | ||
if (allowPartial) { | ||
return true; | ||
} else { | ||
return false; | ||
} | ||
} | ||
@@ -453,0 +459,0 @@ } |
{ | ||
"name": "6to5", | ||
"description": "Turn ES6 code into readable vanilla ES5 with source maps", | ||
"version": "3.3.2", | ||
"version": "3.3.3", | ||
"author": "Sebastian McKenzie <sebmck@gmail.com>", | ||
@@ -6,0 +6,0 @@ "homepage": "https://6to5.org/", |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1397415
11913