Skip to content

Commit dfebf16

Browse files
committed
Setting allTeams works even when teamsImplemented is missing
1 parent aa9ea23 commit dfebf16

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/app/component/mapping/mapping.component.ts

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -154,12 +154,18 @@ export class MappingComponent implements OnInit {
154154
]
155155
);
156156
for (let a = 0; a < activityInCurrentSubDimension.length; a++) {
157-
if (a == 0) {
158-
this.allTeams = Object.keys(
157+
if (!this.allTeams || this.allTeams.length == 0) {
158+
if (
159159
this.YamlObject[this.allDimensionNames[i]][
160160
subdimensionsInCurrentDimension[j]
161161
][activityInCurrentSubDimension[a]]['teamsImplemented']
162-
);
162+
) {
163+
this.allTeams = Object.keys(
164+
this.YamlObject[this.allDimensionNames[i]][
165+
subdimensionsInCurrentDimension[j]
166+
][activityInCurrentSubDimension[a]]['teamsImplemented']
167+
);
168+
}
163169
}
164170
this.setValueandAppendToDatasetSortedbyActivity(
165171
this.allDimensionNames[i],

0 commit comments

Comments
 (0)