daily pastebin goal
46%
SHARE
TWEET

eShop / TEC joins issue

BakerMan Dec 4th, 2013 88 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_action( 'pre_get_posts', 'stop_tec_joins_on_eshop_search', 100 );
  2.  
  3. function stop_tec_joins_on_eshop_search() {
  4.         if ( ! isset($_GET['eshopsearch']) ) return;
  5.         remove_filter( 'posts_join', array( TribeEventsQuery, 'posts_join' ), 10, 2 );
  6.         remove_filter( 'posts_join', array( TribeEventsQuery, 'posts_join_orderby' ), 10, 2 );
  7. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top