Skip to content

Commit 1069505

Browse files
soumak77kensodemann
authored andcommitted
fix(navigation): ensure secondaryId always has a string value (#12641)
1 parent 295fe78 commit 1069505

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/tabs/tabs.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,7 @@ export class Tabs extends Ion implements AfterViewInit, RootNode, ITabs, Navigat
642642
/**
643643
* @private
644644
*/
645-
_getSelectedTabIndex(secondaryId: string, fallbackIndex: number = 0): number {
645+
_getSelectedTabIndex(secondaryId: string = '', fallbackIndex: number = 0): number {
646646
// we found a segment which probably represents which tab to select
647647
const indexMatch = secondaryId.match(/tab-(\d+)/);
648648
if (indexMatch) {

0 commit comments

Comments
 (0)