Automattic\WooCommerce\Internal\DataStores\Orders
DataSynchronizer::__construct
Class constructor.
Метод класса: DataSynchronizer{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$DataSynchronizer = new DataSynchronizer(); $DataSynchronizer->__construct();
Код DataSynchronizer::__construct() DataSynchronizer:: construct WC 10.0.2
public function __construct() { add_filter( 'pre_delete_post', array( $this, 'maybe_prevent_deletion_of_post' ), 10, 2 ); add_action( 'deleted_post', array( $this, 'handle_deleted_post' ), 10, 2 ); add_action( 'woocommerce_new_order', array( $this, 'handle_updated_order' ), 100 ); add_action( 'woocommerce_refund_created', array( $this, 'handle_updated_order' ), 100 ); add_action( 'woocommerce_update_order', array( $this, 'handle_updated_order' ), 100 ); add_action( 'wp_scheduled_auto_draft_delete', array( $this, 'delete_auto_draft_orders' ), 9 ); add_action( 'wp_scheduled_delete', array( $this, 'delete_trashed_orders' ), 9 ); add_filter( 'updated_option', array( $this, 'process_updated_option' ), 999, 3 ); add_filter( 'added_option', array( $this, 'process_added_option' ), 999, 2 ); add_filter( 'deleted_option', array( $this, 'process_deleted_option' ), 999 ); add_action( self::BACKGROUND_SYNC_EVENT_HOOK, array( $this, 'handle_interval_background_sync' ) ); if ( self::BACKGROUND_SYNC_MODE_CONTINUOUS === $this->get_background_sync_mode() ) { add_action( 'shutdown', array( $this, 'handle_continuous_background_sync' ) ); } if ( defined( 'WC_PLUGIN_BASENAME' ) ) { add_action( 'deactivate_' . WC_PLUGIN_BASENAME, function () { $this->unschedule_background_sync(); } ); } }