Skip to content

Commit

Permalink
src/donations: Don't update updatedAt field on iris re-import
Browse files Browse the repository at this point in the history
Since campaign donations are ordered by updatedAt field on the front-end, this causes to bank donations to reappear at top every hour.
Temporary solution until we figure out, the reason updating of imported donation is needed.
  • Loading branch information
sashko9807 committed Jan 22, 2024
1 parent 33a0845 commit 6840875
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/api/src/donations/donations.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ export class DonationsService {
//Donation exists, so updating with incoming donation without increasing vault amounts
await this.prisma.donation.update({
where: { extPaymentIntentId: donationDto.extPaymentIntentId },
data: donationDto,
data: { ...donationDto, updatedAt: existingDonation.updatedAt },
})
return ImportStatus.UPDATED
})
Expand Down

0 comments on commit 6840875

Please sign in to comment.