add handling for duplicate autocomplete entries

I noticed that if a list of autocomplete values has a duplicate string, Angular may throw "Error: Duplicates in a repeater are not allowed." I fixed this in my project and thought it may be useful.