fixes search using regex