Skip to content

Commit b676f01

Browse files
MKirovaMKirova
authored andcommitted
chore(*): Check explicitly for null/undefined in case rowId is 0.
1 parent b9891eb commit b676f01

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,7 @@ export class IgxTreeGridComponent extends IgxGridBaseDirective implements GridTy
526526
protected _getParentRecordId() {
527527
if (this.addRowParent.asChild) {
528528
return super._getParentRecordId();
529-
} else if (this.addRowParent.rowID) {
529+
} else if (this.addRowParent.rowID !== null && this.addRowParent.rowID !== undefined) {
530530
const spawnedForRecord = this._gridAPI.get_rec_by_id(this.addRowParent.rowID);
531531
return spawnedForRecord?.parent?.rowID;
532532
}

0 commit comments

Comments
 (0)