adamsaghy commented on code in PR #4299:
URL: https://github.com/apache/fineract/pull/4299#discussion_r1946170861


##########
fineract-provider/src/main/java/org/apache/fineract/portfolio/loanaccount/service/LoanAccrualsProcessingServiceImpl.java:
##########
@@ -1196,10 +1202,13 @@ private void reverseAccrual(LoanTransaction 
transaction, boolean addEvent) {
     }
 
     private LocalDate getFinalAccrualTransactionDate(Loan loan) {
+        if 
(configurationDomainService.getAccrualDateConfigForCharge().equals(ACCRUAL_ON_CHARGE_SUBMITTED_ON_DATE))
 {
+            return loan.getLastLoanRepaymentScheduleInstallment().getDueDate();
+        }
         return switch (loan.getStatus()) {
             case CLOSED_OBLIGATIONS_MET -> loan.getClosedOnDate();
             case OVERPAID -> loan.getOverpaidOnDate();
-            default -> throw new IllegalStateException("Unexpected value: " + 
loan.getStatus());
+            default -> 
loan.getLastLoanRepaymentScheduleInstallment().getDueDate();

Review Comment:
   Can you please elaborate on this? I am not fully understand the idea here...



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to