Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@searchwpgists
Last active March 16, 2022 16:26
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 searchwpgists/daa2a8c9025eb05c7b6b72f6f3539e88 to your computer and use it in GitHub Desktop.
Save searchwpgists/daa2a8c9025eb05c7b6b72f6f3539e88 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