Merge "Workaround apparent bug in Edge's history.pushState"

This commit is contained in:
jenkins-bot 2015-07-03 20:48:02 +00:00 committed by Gerrit Code Review
commit 036f0fb186

View file

@ -469,7 +469,12 @@
hash = window.location.href.replace( /#.*$/, '' );
}
this.browserHistory.pushState( null, title, hash );
try {
window.history.pushState( null, title, hash );
} catch ( ex ) {
// Workaround for Edge bug -- https://phabricator.wikimedia.org/T104381
window.history.pushState( null, title, hash + '#' );
}
} else {
// Since we voluntarily changed the hash, we don't want MMVB.hash (which will trigger on hashchange event) to treat it
this.skipNextHashHandling = true;