Skip to content

Commit

Permalink
fix: change detection is correctly triggered to build new filters (#1584
Browse files Browse the repository at this point in the history
)

fixes #1570
  • Loading branch information
TheSlimvReal committed Dec 16, 2022
1 parent 9044c39 commit c945150
Showing 1 changed file with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -90,12 +90,14 @@ export class RollCallSetupComponent implements OnInit {
}
}

for (const activity of this.visibleActivities) {
const newEvent = await this.createEventForActivity(activity);
if (newEvent) {
this.existingEvents.push(newEvent);
}
}
const newEvents = await Promise.all(
this.visibleActivities.map((activity) =>
this.createEventForActivity(activity)
)
);
this.existingEvents = this.existingEvents.concat(
...newEvents.filter((e) => !!e)
);
}

async showMore() {
Expand Down

0 comments on commit c945150

Please sign in to comment.