added select callback to autocomplete