Fixing history.replaceState URL changing when form values are changed.