budaidev commented on code in PR #4961:
URL: https://github.com/apache/fineract/pull/4961#discussion_r2309185564


##########
fineract-provider/src/main/java/org/apache/fineract/portfolio/loanaccount/service/LoanReadPlatformServiceImpl.java:
##########
@@ -1969,21 +1980,19 @@ public DisbursementData mapRow(final ResultSet rs, 
@SuppressWarnings("unused") f
             final BigDecimal principal = rs.getBigDecimal("principal");
             final String loanChargeId = rs.getString("loanChargeId");
             final BigDecimal netDisbursalAmount = 
rs.getBigDecimal("netDisbursalAmount");
-            BigDecimal chargeAmount = rs.getBigDecimal("chargeAmount");
-            final BigDecimal waivedAmount = rs.getBigDecimal("waivedAmount");
-            if (chargeAmount != null && waivedAmount != null) {
-                chargeAmount = chargeAmount.subtract(waivedAmount);
-            }
+            final BigDecimal chargeAmount = rs.getBigDecimal("chargeAmount");
+            // Waived amount is already subtracted in SQL aggregation

Review Comment:
   modified



-- 
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