diff --git a/src/compiler/compile/Component.ts b/src/compiler/compile/Component.ts index ce5428805f..454a4ee71c 100644 --- a/src/compiler/compile/Component.ts +++ b/src/compiler/compile/Component.ts @@ -803,12 +803,9 @@ export default class Component { if (node.type === 'CallExpression') { node.arguments.forEach(arg => { - if (arg.type === 'Identifier') { - const { name } = arg; - if (scope.find_owner(name) === instance_scope) { - const variable = component.var_lookup.get(name); - variable.aliased = true; - } + if (arg.type === 'Identifier' && scope.find_owner(arg.name) === instance_scope) { + const variable = component.var_lookup.get(arg.name); + variable.aliased = true; } }); }