added functionality to return first item from a search