replaced location.origin

location.origin is not defined in all browsers.
This commit is contained in:
Doctor-von-Piglet 2015-04-15 12:03:42 -07:00
parent d00b9633c0
commit cde464b6bf

View File

@ -177,7 +177,7 @@ function highlightReply(id, event) {
post.className += ' highlighted'; post.className += ' highlighted';
if (history.pushState) { if (history.pushState) {
history.pushState(null, null, window.document.location.origin + window.document.location.pathname + window.document.location.search + '#' + id); history.pushState(null, null, window.document.location.protocol + "//" + window.document.location.host + window.document.location.pathname + window.document.location.search + '#' + id);
} else { } else {
window.location.hash = id; window.location.hash = id;
} }