refactored Autoomplete