diff --git a/src/compiler/compile/Component.ts b/src/compiler/compile/Component.ts index 454a4ee71c..50db8ec747 100644 --- a/src/compiler/compile/Component.ts +++ b/src/compiler/compile/Component.ts @@ -796,7 +796,7 @@ export default class Component { scope = map.get(node); } - if (node.type === 'VariableDeclarator' && node.id !== null && node.id.type === 'Identifier' && node.init !== null && node.init.type === 'Identifier') { + if (node.type === 'VariableDeclarator' && node.init !== null && node.init.type === 'Identifier') { const variable = component.var_lookup.get(node.init.name); variable.aliased = true; }