Skip to content

Commit

Permalink
Merge pull request apache#532 from vishwasbabu/develop
Browse files Browse the repository at this point in the history
FINERACT-708
  • Loading branch information
vishwasbabu authored Mar 1, 2019
2 parents f115436 + e22216e commit a2adc77
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public class LoanCharge extends AbstractPersistableCustom<Long> {

public static LoanCharge createNewFromJson(final Loan loan, final Charge chargeDefinition, final JsonCommand command) {
final LocalDate dueDate = command.localDateValueOfParameterNamed("dueDate");
if (dueDate == null) {
if (chargeDefinition.getChargeTimeType().equals(ChargeTimeType.SPECIFIED_DUE_DATE.getValue()) && dueDate == null) {
final String defaultUserMessage = "Loan charge is missing due date.";
throw new LoanChargeWithoutMandatoryFieldException("loanCharge", "dueDate", defaultUserMessage, chargeDefinition.getId(),
chargeDefinition.getName());
Expand Down

0 comments on commit a2adc77

Please sign in to comment.