We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 728e676 commit e996caeCopy full SHA for e996cae
src/processScript/transform.ts
@@ -741,12 +741,12 @@ export function transform(
741
let thisId = reuseDeclaredName ? (parent.id as Identifier).name : `_${evenMoreUniqueId}_THIS_`
742
743
let thisIsReferenced = false
744
- if (path.type == `ObjectExpression`) {
+ if (object.type == `ObjectExpression`) {
745
for (const property of (object as ObjectExpression).properties) {
746
if (property.type != `ObjectMethod`)
747
continue
748
749
- thisIsReferenced ||= replaceAllThisWith(object, scope, thisId)
+ thisIsReferenced ||= replaceAllThisWith(property, scope, thisId)
750
}
751
} else {
752
for (const element of (object as ArrayExpression).elements) {
0 commit comments