minor comment changes
moved utility methods outside of typeahead file