UA detection fix