Skip to content

Instantly share code, notes, and snippets.

@jchristopher
Created March 23, 2020 19:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jchristopher/43f4f442b7667ea9ceab93866037a47c to your computer and use it in GitHub Desktop.
Save jchristopher/43f4f442b7667ea9ceab93866037a47c to your computer and use it in GitHub Desktop.
Make SearchWP's fuzzy matching more strict
<?php
// Make SearchWP's fuzzy matching more strict.
// The scale is 0-100 going from furthest match (lowest, 0)
// to closest match (highest, 100).
add_filter( 'searchwp\query\partial_matches\fuzzy\threshold', function( $threshold ) {
return 80;
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment