improving exception handling
This commit is contained in:
@@ -151,8 +151,12 @@ public class MPGSWebPaymentProcessor implements TransactionProcessorInterface {
|
|||||||
transaction.setResponseCode("00");
|
transaction.setResponseCode("00");
|
||||||
transaction.setTargetUrl((String) body.get("targetUrl"));
|
transaction.setTargetUrl((String) body.get("targetUrl"));
|
||||||
|
|
||||||
LinkedHashMap transactionData = (LinkedHashMap) body.get("transaction");
|
try {
|
||||||
transaction.setDebitRef((String) transactionData.get("sdkActionId"));
|
LinkedHashMap transactionData = (LinkedHashMap) body.get("transaction");
|
||||||
|
transaction.setDebitRef((String) transactionData.get("creditReference"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.info("Notification not yet posted at the bank");
|
||||||
|
}
|
||||||
|
|
||||||
transactionService.save(transaction);
|
transactionService.save(transaction);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user