Skip to content

Instantly share code, notes, and snippets.

@jchristopher
Created February 14, 2019 16:17
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Determine whether SearchWP should be forced to use fuzzy logic even if partial matches are found
<?php
function my_searchwp_partial_matches_force_fuzzy( $return, $args ) {
// $args contains information about this request
// - engine
// TODO: customize $return to match whether fuzzy logic should be forced
// when partial matches are already found
return $return;
}
add_filter( 'searchwp_partial_matches_force_fuzzy', 'my_searchwp_partial_matches_force_fuzzy', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment