Added error handling and load bar to front-end