-
-
Save searchwpgists/34bdd40a7b6e5e28f59b1b686dece4fc to your computer and use it in GitHub Desktop.
Always add 'coffee' to SearchWP partial matches even if it's not
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
<?php | |
// Always add 'coffee' to partial matches even if it's not. | |
add_filter( 'searchwp\query\partial_matches\tokens', function( $partial_match_tokens, $args ) { | |
$partial_match_tokens[] = 'coffee'; | |
return $partial_match_tokens; | |
}, 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment