Skip to content

Commit

Permalink
fix[DonationService]: Change timestamp syntax to better readability a…
Browse files Browse the repository at this point in the history
…nd usability
  • Loading branch information
Fredrik Marjoni committed Mar 3, 2026
1 parent 6b313cc commit a8f6f9f
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
package edu.group5.app.service;
import java.time.Instant;

import java.math.BigDecimal;
import java.sql.Timestamp;
Expand Down Expand Up @@ -55,7 +56,7 @@ public boolean donate(Customer customer, int orgNumber, BigDecimal amount) {
return false;
}
Donation donation = new Donation(customer.getUserId(), org.getOrgNumber(),
amount, new Timestamp(System.currentTimeMillis()));
amount, Timestamp.from(Instant.now()));
donationRepository.addDonation(donation);
return true;
}
Expand Down

0 comments on commit a8f6f9f

Please sign in to comment.