fix: correctly transform __proto__ properties (#12664)

* fix: correctly transform `__proto__` properties

* fixup! fix: correctly transform `__proto__` properties
This commit is contained in:
ExE Boss
2021-01-22 10:58:33 +01:00
committed by GitHub
parent 2811b535d6
commit f1314a1683
9 changed files with 52 additions and 5 deletions

View File

@@ -90,8 +90,6 @@ export default declare((api, options) => {
if (prop.kind === "get" || prop.kind === "set") {
pushMutatorDefine(info, prop);
} else if (t.isStringLiteral(key, { value: "__proto__" })) {
pushAssign(objId, prop, body);
} else {
if (computedProps.length === 1) {
return t.callExpression(state.addHelper("defineProperty"), [