Added time out handler for spinner and global error handling