adding update ui function
added support for updateUI on error.
added disabling of search bar on searching