Skip to content

Commit

Permalink
feat: clearing issuers instead of exception PAGOPA-2388
Browse files Browse the repository at this point in the history
  • Loading branch information
FedericoRuzzier committed Nov 18, 2024
1 parent c65b7b1 commit c5470fa
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,9 @@ private List<Transfer> calculateTaxPayerFee(
// is raised
// - the limit(2) operation is used to terminate as soon as two distinct ABI objects are found
if (isUniqueAbi(issuers)) {
throw new AppException(AppError.ISSUERS_BIN_WITH_DIFFERENT_ABI_ERROR, paymentOption.getBin());
// fix to solve the problem with overlapping ranges of some psps
issuers.clear();
//throw new AppException(AppError.ISSUERS_BIN_WITH_DIFFERENT_ABI_ERROR, paymentOption.getBin());
}

for (ValidBundle bundle : bundles) {
Expand Down Expand Up @@ -157,7 +159,9 @@ private List<it.gov.pagopa.afm.calculator.model.calculatormulti.Transfer> calcul
// is raised
// - the limit(2) operation is used to terminate as soon as two distinct ABI objects are found
if (isUniqueAbi(issuers)) {
throw new AppException(AppError.ISSUERS_BIN_WITH_DIFFERENT_ABI_ERROR, paymentOption.getBin());
// fix to solve the problem with overlapping ranges of some psps
issuers.clear();
//throw new AppException(AppError.ISSUERS_BIN_WITH_DIFFERENT_ABI_ERROR, paymentOption.getBin());
}

for (ValidBundle bundle : bundles) {
Expand Down

0 comments on commit c5470fa

Please sign in to comment.