File tree 1 file changed +2
-3
lines changed
plugin/src/PaymentGateways
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -124,13 +124,12 @@ public function __construct()
124
124
public function process_payment ($ order_id )
125
125
{
126
126
try {
127
- $ request = $ _POST ;
128
127
$ order = new WC_Order ($ order_id );
129
128
130
129
$ this ->checkOrderCanBePaid ($ order );
131
130
$ this ->checkUserIsLoggedIn ();
132
131
133
- return $ this ->handleRequest ( $ request , $ order );
132
+ return $ this ->handleOneclickPayment ( $ _POST , $ order );
134
133
} catch (Throwable $ exception ) {
135
134
$ errorHookName = 'wc_gateway_transbank_process_payment_error_ ' . $ this ->id ;
136
135
$ errorMessage = ErrorHelper::getErrorMessageBasedOnTransbankSdkException ($ exception );
@@ -336,7 +335,7 @@ public function form()
336
335
*
337
336
* @return array The result of the processing, including a success message and redirect URL.
338
337
*/
339
- private function handleRequest (array $ request , WC_Order $ order )
338
+ private function handleOneclickPayment (array $ request , WC_Order $ order )
340
339
{
341
340
$ paymentTokenId = wc_clean ($ request ["wc- {$ this ->id }-payment-token " ]) ?? null ;
342
341
You can’t perform that action at this time.
0 commit comments