function gotta_go_fast() { // Remove default action scheduler comment clause filter remove_action('pre_get_comments', array(ActionScheduler_Logger::instance(), 'filter_comment_queries'), 10, 1); // Add our own filter add_action('pre_get_comments', 'the_magic', 10, 1); }
public function __construct() { add_action('plugins_loaded', array($this, 'wcs_remove_deprecation_handlers'), 0); // Remove default action scheduler comment clause filter remove_action('pre_get_comments', array(ActionScheduler_Logger::instance(), 'filter_comment_queries'), 10, 1); // Add our own filter add_action('pre_get_comments', array($this, 'the_magic'), 10, 1); // If running WooCommerce, remove their filter so that nothing funky goes down remove_filter('wp_count_comments', array('WC_Comments', 'wp_count_comments'), 10); // Remove unmoderated comment counts from the admin menu add_filter('wp_count_comments', array($this, 'pmgarman_unmoderated_comment_counts'), 10, 2); // Order counts in the admin menu can be removed once this filter is merged into WooCommerce // https://github.com/woothemes/woocommerce/pull/9820 add_filter('woocommerce_include_order_count_in_menu', '__return_false'); // Remove WC Status Dashboard Widget add_action('wp_dashboard_setup', array($this, 'example_remove_dashboard_widget')); }
public static function logger() { return ActionScheduler_Logger::instance(); }