Skip to content

Commit

Permalink
Merge pull request #989 from payplug/SMP-3059
Browse files Browse the repository at this point in the history
SMP-3059 : add fail safe for integrated payment
  • Loading branch information
PPmmesquita authored Feb 17, 2025
2 parents 2125951 + 6e2bba5 commit 66dccff
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions assets/js/payplug-integrated-payments.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,15 +205,18 @@ var IntegratedPayment = {
IntegratedPayment.props.return_url = response.redirect;
},
complete: function(response) {
if (response.responseJSON.result != "failure") {
if (IntegratedPayment.oneClickSelected()) {
return;
if (response.responseJSON != null) {
if (response.responseJSON.result != "failure") {
if (IntegratedPayment.oneClickSelected()) {
return;

} else {
IntegratedPayment.SubmitPayment();
} else {
IntegratedPayment.SubmitPayment();

}
}
}

}
});
},
Expand Down

0 comments on commit 66dccff

Please sign in to comment.