added popstate listener