diff --git a/lib/6to5/transformation/helpers/replace-supers.js b/lib/6to5/transformation/helpers/replace-supers.js index 4ec70cf6b5..2403e878cb 100644 --- a/lib/6to5/transformation/helpers/replace-supers.js +++ b/lib/6to5/transformation/helpers/replace-supers.js @@ -152,7 +152,7 @@ ReplaceSupers.prototype.getThisReference = function () { return this.topLevelThisReference; } else { var ref = this.topLevelThisReference = this.file.generateUidIdentifier("this"); - this.methodNode.body.body.unshift(t.variableDeclaration("var", [ + this.methodNode.value.body.body.unshift(t.variableDeclaration("var", [ t.variableDeclarator(this.topLevelThisReference, t.thisExpression()) ])); return ref;