Automattic\WooCommerce\Internal

McStats::do_server_side_statpublicWC 1.0

Runs stats code for a one-off, server-side.

Method of the class: McStats{}

No Hooks.

Returns

true|false. If it worked.

Usage

$McStats = new McStats();
$McStats->do_server_side_stat( $url );
$url(string) (required)
string The URL to be pinged. Should include x_woocommerce-{$group}={$stats} or whatever we want to store.

McStats::do_server_side_stat() code WC 9.9.5

public function do_server_side_stat( $url ) {
	if ( ! \WC_Site_Tracking::is_tracking_enabled() ) {
		return false;
	}

	return parent::do_server_side_stat( $url );
}