Last active
March 3, 2023 13:39
-
-
Save pehaa/77949f47a2a95ea263a2a495a9c7543a to your computer and use it in GitHub Desktop.
jetpack_instant_search_options
This file contains 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
add_filter( 'jetpack_instant_search_options', function($options) { | |
$lang = pll_current_language(); | |
$options['adminQueryFilter'] = array( | |
'bool' => array( | |
'must' => array( | |
array( 'term' => array( 'taxonomy.language.slug' => $lang ) ), | |
) | |
) | |
); | |
return $options; | |
} ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment