diff --git a/src/compile/render-dom/wrappers/Slot.ts b/src/compile/render-dom/wrappers/Slot.ts index 440590239d..de866ed882 100644 --- a/src/compile/render-dom/wrappers/Slot.ts +++ b/src/compile/render-dom/wrappers/Slot.ts @@ -141,7 +141,7 @@ export default class SlotWrapper extends Wrapper { if (this.dependencies.size > 1) update_conditions = `(${update_conditions})`; block.builders.update.addBlock(deindent` - if (${slot} && ${update_conditions}) { + if (${slot} && ${slot}.p && ${update_conditions}) { ${slot}.p(@assign(@assign({}, ${get_slot_changes}(changed)), ctx.$$scope.changed), @get_slot_context(${slot_definition}, ctx, ${get_slot_context})); } `); @@ -150,4 +150,4 @@ export default class SlotWrapper extends Wrapper { `if (${slot}) ${slot}.d(detach);` ); } -} \ No newline at end of file +}