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 e5c643b commit f7dc47fCopy full SHA for f7dc47f
core/src/components/toolbar/toolbar.tsx
@@ -112,11 +112,7 @@ export class Toolbar implements ComponentInterface {
112
113
private hasSlotContent(slotName: string): boolean {
114
const slotNode = this.el.shadowRoot?.querySelector(`slot[name="${slotName}"]`) as HTMLSlotElement | null;
115
- if (slotNode) {
116
- const assigned = slotNode.assignedNodes();
117
- return assigned.length > 0;
118
- }
119
- return false;
+ return !!slotNode && slotNode.assignedNodes().length > 0;
120
}
121
122
@Listen('ionStyle')
0 commit comments