Fixed an issue with autocomplete not working