trimming search string