i need to exclude last letter from search string, because WP search is word sensitive.
I mean the situations like user entered word "dogs" but in titles i have no dogs, i have "dog". In this case user gets 0 results, but if we filtered search string and remove last letter, before sending search results user gets results from "dog".
Code is simple
$word = substr($word, 0, -1);
Where $word is a search string. But i can't find a hook. Is there any filter or hook, or where is processing search string file?