Skip to content

Commit

Permalink
Merge pull request #45369 from dominictb/fix/44833-hidden
Browse files Browse the repository at this point in the history
fix: check empty array for report participants
  • Loading branch information
carlosmiceli authored Jul 15, 2024
2 parents 1f28763 + 793c88e commit 7468c85
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libs/migrations/Participants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ export default function (): Promise<void> {
}

const collection = Object.entries(reports).reduce<OldReportCollection>((reportsCollection, [onyxKey, report]) => {
// If we have participantAccountIDs then this report is eligible for migration
if (report?.participantAccountIDs) {
// If we have non-empty participantAccountIDs then this report is eligible for migration
if (report?.participantAccountIDs?.length) {
const participants: NullishDeep<Participants> = {};

const deprecatedParticipants = new Set(report.participantAccountIDs);
Expand Down

0 comments on commit 7468c85

Please sign in to comment.