diff --git a/inc/mep_functions.php b/inc/mep_functions.php index fe5429a..ad44885 100755 --- a/inc/mep_functions.php +++ b/inc/mep_functions.php @@ -4669,19 +4669,21 @@ function mep_change_global_option_section($option_name, $old_sec_name, $new_sec_ } -add_action( 'pre_get_posts', 'mep_search_query_exlude_hidden_wc_fix' ); -function mep_search_query_exlude_hidden_wc_fix( $query = false ) { - if(!is_admin() && is_search()){ - $query->set( 'tax_query', array( - array( - 'taxonomy' => 'product_visibility', - 'field' => 'name', - 'terms' => 'exclude-from-search', - 'operator' => 'NOT IN', - ) - )); - } -} + add_action( 'pre_get_posts', 'mep_search_query_exlude_hidden_wc_fix' ); + function mep_search_query_exlude_hidden_wc_fix( $query ) { + if ($query->is_search && !is_admin() ) { + $query -> set( 'tax_query', array( + array( + 'taxonomy' => 'product_visibility', + 'field' => 'name', + 'terms' => 'exclude-from-search', + 'operator' => 'NOT IN', + ) + )); + + } + return $query; + } function mep_check_plugin_installed($path){ diff --git a/woocommerce-event-press.php b/woocommerce-event-press.php index ea54663..d78de4d 100644 --- a/woocommerce-event-press.php +++ b/woocommerce-event-press.php @@ -3,7 +3,7 @@ * Plugin Name: Event Manager and Tickets Selling Plugin for WooCommerce * Plugin URI: http://mage-people.com * Description: A Complete Event Solution for WordPress by MagePeople.. - * Version: 3.6.8 + * Version: 3.6.9 * Author: MagePeople Team * Author URI: http://www.mage-people.com/ * Text Domain: mage-eventpress