Skip to content

Commit

Permalink
typescript workarounds:
Browse files Browse the repository at this point in the history
  • Loading branch information
aletya committed May 31, 2024
1 parent ed7f068 commit 01d32f2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/services/stats/stats-router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,18 @@ statsRouter.get(
none++;
}

attendee.dietary_restrictions.forEach((dietary_restriction) => {
const attendee_dietary_restrictions: string[] =
attendee.dietary_restrictions;
attendee_dietary_restrictions.forEach((dietary_restriction) => {
if (dietary_restriction_counts[dietary_restriction]) {
dietary_restriction_counts[dietary_restriction]++;
} else {
dietary_restriction_counts[dietary_restriction] = 1;
}
});

attendee.allergies.forEach((allergies) => {
const attendee_allergies: string[] = attendee.allergies;
attendee_allergies.forEach((allergies) => {
if (allergy_counts[allergies]) {
allergy_counts[allergies]++;
} else {
Expand Down

0 comments on commit 01d32f2

Please sign in to comment.