Fix history API issue

Certain browsers fire a useless popstate on pageload. This is not
new, but the old workaround didn't work anymore on Chrome 19+