WooCommerce::legacy_rest_api_is_available()publicWC 1.0

Check if the Legacy REST API plugin is active (and thus the Legacy REST API is available).

Method of the class: WooCommerce{}

No Hooks.

Return

true|false.

Usage

$WooCommerce = new WooCommerce();
$WooCommerce->legacy_rest_api_is_available();

WooCommerce::legacy_rest_api_is_available() code WC 9.4.2

public function legacy_rest_api_is_available() {
	return class_exists( 'WC_Legacy_REST_API_Plugin', false );
}