Dealing with url errors for production mode