Cocoa-Puffs commented on code in PR #4877:
URL: https://github.com/apache/fineract/pull/4877#discussion_r2222217751
##########
fineract-progressive-loan/src/main/java/org/apache/fineract/portfolio/loanaccount/service/ProgressiveLoanTransactionValidatorImpl.java:
##########
@@ -137,7 +137,7 @@ public void validateCapitalizedIncome(final JsonCommand
command, final Long loan
final BigDecimal newTotal =
totalDisbursed.add(capitalizedIncome).add(transactionAmount);
if
(loan.loanProduct().isAllowApprovedDisbursedAmountsOverApplied()) {
- final BigDecimal maxAppliedAmount =
getOverAppliedMax(loan);
+ final BigDecimal maxAppliedAmount =
loanMaximumAmountValidator.getOverAppliedMax(loan);
if (newTotal.compareTo(maxAppliedAmount) > 0) {
baseDataValidator.reset().parameter("transactionAmount").failWithCode("exceeds.approved.amount",
Review Comment:
Should we consider changing the error code? We aren't really comparing the
transaction amount to the approved amount in this case.
--
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]