Skip to content

Commit 2a5cac2

Browse files
committed
minor fixes
1 parent dd811b7 commit 2a5cac2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/class-wc-gateway-criptomarket.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ function update_order_states() {
306306
$order = wc_get_order($order_id);
307307
$order_states = $this->get_option('order_states');
308308

309-
if (false === $order || 'WC_Order' !== get_class($order)) {
309+
if (false === $order) {
310310
$this->log('[Error] The Plugin was called but could not retrieve the order details for order_id: "' . $order_id . '". If you use an alternative order numbering system, please see class-wc-gateway-cryptomarket.php to apply a search filter.');
311311
throw new \Exception('The Plugin was called but could not retrieve the order details for order_id ' . $order_id . '. Cannot continue!');
312312
} else {
@@ -506,7 +506,7 @@ public function process_payment($order_id) {
506506
'to_receive' => $total_order,
507507
'external_id' => $order->get_id(),
508508
'callback_url' => str_replace('https:', 'http:', add_query_arg('wc-api','WC_Gateway_cryptomarket', home_url( '/' ))),
509-
'error_url' => WC()->cart->get_checkout_url(),
509+
'error_url' => wc_get_checkout_url(),
510510
'success_url' => $success_return_url,
511511
'refund_email' => $order->get_billing_email(),
512512
'language' => explode('_', get_locale())[0]

0 commit comments

Comments
 (0)