Fixes all params being removed and extra slash at the end.