Commit 11207c7550df908713542a71779b621b25e296b8
1 parent
60a601d7
Fix get enity relation infoes for empty array
Showing
1 changed file
with
1 additions
and
1 deletions
@@ -1006,7 +1006,7 @@ export class EntityService { | @@ -1006,7 +1006,7 @@ export class EntityService { | ||
1006 | 1006 | ||
1007 | private entityRelationInfosToEntitiesInfo(entityRelations: Array<EntityRelationInfo>, | 1007 | private entityRelationInfosToEntitiesInfo(entityRelations: Array<EntityRelationInfo>, |
1008 | direction: EntitySearchDirection): Observable<Array<EntityInfo>> { | 1008 | direction: EntitySearchDirection): Observable<Array<EntityInfo>> { |
1009 | - if (entityRelations) { | 1009 | + if (entityRelations.length) { |
1010 | const tasks: Observable<EntityInfo>[] = []; | 1010 | const tasks: Observable<EntityInfo>[] = []; |
1011 | entityRelations.forEach((entityRelation) => { | 1011 | entityRelations.forEach((entityRelation) => { |
1012 | tasks.push(this.entityRelationInfoToEntityInfo(entityRelation, direction)); | 1012 | tasks.push(this.entityRelationInfoToEntityInfo(entityRelation, direction)); |