replaceState fix