Skip to content

Commit 43e99d1

Browse files
committed
ButtonRadio: ignore undefined sections
1 parent 3cc1dd5 commit 43e99d1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

views/ButtonRadio.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ export default class ButtonRadio {
8787
// Button bar
8888
return m(`div#${id}.btn-group.btn-group-toggle${vertical ? '.btn-group-vertical' : ''}[role=group]`,
8989
mergeAttributes({style: {'width': '100%'}}, attrsAll),
90-
sections.map(section =>
90+
sections.filter(_=>_).map(section =>
9191
// Individual buttons
9292
m(`#${section.id || 'btn' + section.value}.btn.btn-secondary${
9393
String(section.value).toLowerCase() === this.active.toLowerCase() ? '.active' : ''}`,

0 commit comments

Comments
 (0)