Making typeahead work with object values