Skip to content

Commit 284cb62

Browse files
committed
fix for message 'Click the button below to retry payment' showing after payment is successful, on callback
1 parent 36f7368 commit 284cb62

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

modules/gateways/paystack.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,9 @@ function paystack_link($params)
185185
currency: \''.addslashes(trim($currency)).'\',
186186
ref:\''.$txnref.'\',
187187
callback: function(response){
188+
$(\'div.alert.alert-info.text-center\').hide();
189+
$(\'.payment-btn-container2\').hide();
190+
188191
window.location.href = \''.addslashes($callbackUrl).'&trxref=\' + response.trxref;
189192
},
190193
onClose: function(){
@@ -214,7 +217,7 @@ function create_button(){
214217
'<img style="width: 150px; display: block; margin: 0 auto;"'.
215218
' src="https://paystack.com/assets/website/images/brand/badges/cards.png"/>\');
216219
}
217-
}
220+
}
218221
' . ( $paynowload ? 'setTimeout("payWithPaystack()", 5100);' : '' ) . '
219222
</script>';
220223

0 commit comments

Comments
 (0)