Skip to content

Commit 3c3bf0d

Browse files
robertmesserlejelbourn
authored andcommitted
refactor(tabs): simplifies tab existence check (#648)
1 parent 231467d commit 3c3bf0d

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
@@ -64,7 +64,7 @@ export class MdTabGroup {
6464
* ViewChildren references are ready.
6565
*/
6666
private get _currentLabelWrapper(): HTMLElement {
67-
return this._labelWrappers && this._labelWrappers.toArray()[this.selectedIndex]
67+
return this._labelWrappers && this._labelWrappers.length
6868
? this._labelWrappers.toArray()[this.selectedIndex].elementRef.nativeElement
6969
: null;
7070
}

0 commit comments

Comments
 (0)