Fix to redirects to play nice with Tomcat.