Server IP : 162.0.217.223 / Your IP : 216.73.216.153 Web Server : LiteSpeed System : Linux premium269.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : mypckeys ( 1539) PHP Version : 8.1.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/mypckeys/yeslicense.org/wp-content/plugins/woo-wallet/includes/ |
Upload File : |
<?php /** * Helper class file. * * @package StandaleneTech */ if ( ! defined( 'ABSPATH' ) ) { exit; } /** * Provides static methods as helpers. */ class WOO_Wallet_Helper { /** * Save order meta data. * * @param WC_Order|int $order order. * @param string $key key. * @param mixed $value value. * @param bool $do_save do_save. * @return void */ public static function update_order_meta_data( $order, $key, $value, $do_save = true ) : void { if ( ! $order instanceof WC_Order ) { $order = wc_get_order( $order ); } if ( is_callable( array( $order, 'update_meta_data' ) ) ) { $order->update_meta_data( $key, $value ); } if ( is_callable( array( $order, 'save' ) ) && $do_save ) { $order->save(); } } }