add filter to allow WC Admin to be disabled (https://github.com/woocommerce/woocommerce-admin/pull/3350)
This commit is contained in:
parent
cd6c81ae22
commit
0c5c0f1571
|
@ -54,6 +54,15 @@ class FeaturePlugin {
|
||||||
* Init the feature plugin, only if we can detect both Gutenberg and WooCommerce.
|
* Init the feature plugin, only if we can detect both Gutenberg and WooCommerce.
|
||||||
*/
|
*/
|
||||||
public function init() {
|
public function init() {
|
||||||
|
/**
|
||||||
|
* Filter allowing WooCommerce Admin to be disabled.
|
||||||
|
*
|
||||||
|
* @param bool $disabled False.
|
||||||
|
*/
|
||||||
|
if ( apply_filters( 'woocommerce_analytics_disabled', false ) ) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
$this->define_constants();
|
$this->define_constants();
|
||||||
|
|
||||||
require_once WC_ADMIN_ABSPATH . '/includes/core-functions.php';
|
require_once WC_ADMIN_ABSPATH . '/includes/core-functions.php';
|
||||||
|
|
Loading…
Reference in New Issue