Skip to content

Commit 3f35912

Browse files
committed
FINERACT-2567: Fix error messages in exception classes
1 parent bbece9c commit 3f35912

12 files changed

Lines changed: 22 additions & 22 deletions

File tree

fineract-accounting/src/main/java/org/apache/fineract/accounting/glaccount/exception/GLAccountInvalidUpdateException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public enum GlAccountInvalidUpdateReason {
3232

3333
public String errorMessage() {
3434
if (name().equalsIgnoreCase("TRANSANCTIONS_LOGGED")) {
35-
return "This Usage of this (detail) GL Account as it already has transactions logged against it";
35+
return "This (detail) GL Account cannot be updated as it already has transactions logged against it";
3636
}
3737
return name();
3838
}

fineract-charge/src/main/java/org/apache/fineract/portfolio/charge/exception/LoanChargeCannotBeDeletedException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class LoanChargeCannotBeDeletedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Loan Charge cannot be deleted **/
2626
public enum LoanChargeCannotBeDeletedReason {
2727

2828
ALREADY_PAID, //

fineract-charge/src/main/java/org/apache/fineract/portfolio/charge/exception/LoanChargeCannotBePayedException.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class LoanChargeCannotBePayedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Loan Charge cannot be paid **/
2626
public enum LoanChargeCannotBePayedReason {
2727

2828
ALREADY_PAID, //
@@ -37,11 +37,11 @@ public String errorMessage() {
3737
} else if (name().equalsIgnoreCase("ALREADY_WAIVED")) {
3838
return "This loan charge has already been waived";
3939
} else if (name().equalsIgnoreCase("LOAN_INACTIVE")) {
40-
return "This loan charge can be payed as the loan associated with it is currently inactive";
40+
return "This loan charge cannot be paid as the loan associated with it is currently inactive";
4141
} else if (name().equalsIgnoreCase("CHARGE_NOT_ACCOUNT_TRANSFER")) {
42-
return "This loan charge can be payed as the charge payment mode is not account transfer";
42+
return "This loan charge cannot be paid as the charge payment mode is not account transfer";
4343
} else if (name().equalsIgnoreCase("CHARGE_NOT_PAYABLE")) {
44-
return "This loan charge is not Payable through account transfer";
44+
return "This loan charge is not payable through account transfer";
4545
}
4646

4747
return name();

fineract-charge/src/main/java/org/apache/fineract/portfolio/charge/exception/LoanChargeCannotBeUpdatedException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class LoanChargeCannotBeUpdatedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Loan Charge cannot be updated **/
2626
public enum LoanChargeCannotBeUpdatedReason {
2727

2828
ALREADY_PAID, //

fineract-charge/src/main/java/org/apache/fineract/portfolio/charge/exception/LoanChargeCannotBeWaivedException.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ public String errorMessage() {
3636
} else if (name().equalsIgnoreCase("ALREADY_WAIVED")) {
3737
return "This loan charge has already been waived";
3838
} else if (name().equalsIgnoreCase("LOAN_INACTIVE")) {
39-
return "This loan charge can be waived as the loan associated with it is currently inactive";
39+
return "This loan charge cannot be waived as the loan associated with it is currently inactive";
4040
} else if (name().equalsIgnoreCase("WAIVE_NOT_ALLOWED_FOR_CHARGE")) {
41-
return "This loan charge can be waived";
41+
return "This loan charge cannot be waived";
4242
}
4343

4444
return name();

fineract-charge/src/main/java/org/apache/fineract/portfolio/charge/exception/LoanChargeWaiveCannotBeReversedException.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@ public enum LoanChargeWaiveCannotUndoReason {
3535
public String errorMessage() {
3636

3737
if (name().equalsIgnoreCase("ALREADY_PAID")) {
38-
return "This loan charge has been completely paid";
38+
return "This loan charge waive cannot be reversed as the charge has already been paid";
3939
} else if (name().equalsIgnoreCase("ALREADY_WAIVED")) {
4040
return "This loan charge has already been waived";
4141
} else if (name().equalsIgnoreCase("LOAN_INACTIVE")) {
42-
return "This loan charge can be waived as the loan associated with it is currently inactive";
42+
return "This loan charge waive cannot be reversed as the loan associated with it is currently inactive";
4343
} else if (name().equalsIgnoreCase("WAIVE_NOT_ALLOWED_FOR_CHARGE")) {
44-
return "This loan charge can be waived";
44+
return "This loan charge waive cannot be reversed";
4545
} else if (name().equalsIgnoreCase("NOT_WAIVED")) {
4646
return "This loan charge waive cannot be reversed as this charge is not waived";
4747
} else if (name().equalsIgnoreCase("ALREADY_REVERSED")) {

fineract-provider/src/main/java/org/apache/fineract/portfolio/collateral/exception/CollateralCannotBeCreatedException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class CollateralCannotBeCreatedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Collateral cannot be created **/
2626
public enum LoanCollateralCannotBeCreatedReason {
2727

2828
LOAN_NOT_IN_SUBMITTED_AND_PENDING_APPROVAL_STAGE;

fineract-provider/src/main/java/org/apache/fineract/portfolio/collateral/exception/CollateralCannotBeDeletedException.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,14 @@
2222

2323
public class CollateralCannotBeDeletedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Collateral cannot be deleted **/
2626
public enum LoanCollateralCannotBeDeletedReason {
2727

2828
LOAN_NOT_IN_SUBMITTED_AND_PENDING_APPROVAL_STAGE;
2929

3030
public String errorMessage() {
3131
if (name().toString().equalsIgnoreCase("LOAN_NOT_IN_SUBMITTED_AND_PENDING_APPROVAL_STAGE")) {
32-
return "This collateral cannot be updated as the loan it is associated with is not in submitted and pending approval stage";
32+
return "This collateral cannot be deleted as the loan it is associated with is not in submitted and pending approval stage";
3333
}
3434
return name().toString();
3535
}

fineract-provider/src/main/java/org/apache/fineract/portfolio/collateral/exception/CollateralCannotBeUpdatedException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class CollateralCannotBeUpdatedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Loan Charge cannot be waived **/
25+
/*** enum of reasons of why Collateral cannot be updated **/
2626
public enum LoanCollateralCannotBeUpdatedReason {
2727

2828
LOAN_NOT_IN_SUBMITTED_AND_PENDING_APPROVAL_STAGE;

fineract-provider/src/main/java/org/apache/fineract/portfolio/collateralmanagement/exception/ClientCollateralCannotBeDeletedException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
public class ClientCollateralCannotBeDeletedException extends AbstractPlatformDomainRuleException {
2424

25-
/*** enum of reasons of why Collateral cannot be waived **/
25+
/*** enum of reasons of why Client Collateral cannot be deleted **/
2626
public enum ClientCollateralCannotBeDeletedReason {
2727

2828
CLIENT_COLLATERAL_IS_ALREADY_ATTACHED;

0 commit comments

Comments
 (0)