modified routeTo to remove parameters from the query string that are replaced in the path