Fixed problem with redirects