updated the error handling and removed default loading text as it was only for debugging.