diff --git a/fineract-provider/src/main/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStep.java b/fineract-provider/src/main/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStep.java index 944031579..fc815f937 100644 --- a/fineract-provider/src/main/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStep.java +++ b/fineract-provider/src/main/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStep.java @@ -81,6 +81,6 @@ public class CheckLoanRepaymentDueBusinessStep implements LoanCOBBusinessStep { return repaymentDate.minusDays(numberOfDaysBeforeDueDateToRaiseEvent).equals(currentDate) && !nonDisbursedStatuses.contains(loan.getStatus()) && loan.getLoanSummary().getTotalOutstanding().compareTo(BigDecimal.ZERO) > 0 - && repaymentScheduleInstallment.getDue(loan.getCurrency()).isGreaterThanZero(); + && repaymentScheduleInstallment.getTotalOutstanding(loan.getCurrency()).isGreaterThanZero(); } } diff --git a/fineract-provider/src/test/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStepTest.java b/fineract-provider/src/test/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStepTest.java index 5376ad815..6b193ad7c 100644 --- a/fineract-provider/src/test/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStepTest.java +++ b/fineract-provider/src/test/java/org/apache/fineract/cob/loan/CheckLoanRepaymentDueBusinessStepTest.java @@ -92,7 +92,7 @@ public class CheckLoanRepaymentDueBusinessStepTest { when(loanForProcessing.getLoanSummary()).thenReturn(loanSummary); when(loanForProcessing.getLoanSummary().getTotalOutstanding()).thenReturn(BigDecimal.ONE); when(loanForProcessing.getCurrency()).thenReturn(currency); - when(repaymentInstallment.getDue(currency)).thenReturn(money); + when(repaymentInstallment.getTotalOutstanding(currency)).thenReturn(money); when(money.isGreaterThanZero()).thenReturn(true); // when @@ -150,7 +150,7 @@ public class CheckLoanRepaymentDueBusinessStepTest { when(loanForProcessing.getLoanSummary()).thenReturn(loanSummary); when(loanForProcessing.getLoanSummary().getTotalOutstanding()).thenReturn(BigDecimal.ONE); when(loanForProcessing.getCurrency()).thenReturn(currency); - when(repaymentInstallment.getDue(currency)).thenReturn(money); + when(repaymentInstallment.getTotalOutstanding(currency)).thenReturn(money); when(money.isGreaterThanZero()).thenReturn(true); // when