Created
July 24, 2024 08:29
-
-
Save adrianduffell/779f67b53b12d75e8608b1bb1a758203 to your computer and use it in GitHub Desktop.
WooCommerce usage tracking opt-out
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: WooCommerce usage tracking opt-out | |
* Author: Adrian Duffell | |
* Description: Automatically opts-out of usage tracking in WooCommerce. https://woocommerce.com/usage-tracking/ | |
* Version: 1.0.0 | |
*/ | |
add_filter('pre_option_woocommerce_allow_tracking', 'opt_out_woocommerce_tracking'); | |
function opt_out_woocommerce_tracking() { | |
return 'no'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment