Skip to content

Commit

Permalink
Merge pull request #3801 from OpenLiberty/replace-to-href-steve
Browse files Browse the repository at this point in the history
Replaced .replace to .href
  • Loading branch information
SteveSamJacob19 committed Jul 11, 2024
2 parents 7bb764a + eb3fce3 commit 04ec17b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/main/content/_assets/js/antora-redirect.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $(document).ready(function () {
if (hash.indexOf("#") === 0) {
hash = hash.substring(1); // Remove hash
}
window.location.replace(window.location.origin + "/docs/latest/" + hash);
window.location.href= window.location.origin + "/docs/latest/" + hash;
} else if (
path.indexOf("/docs/ref/feature/") > -1 ||
path.indexOf("/docs/ref/config/") > -1 ||
Expand Down Expand Up @@ -48,13 +48,12 @@ $(document).ready(function () {
break;
}
}
window.location.replace(
window.location.href =
window.location.origin +
"/docs/latest/reference/" +
resource_type +
"/" +
page +
hash
);
hash;
}
});

0 comments on commit 04ec17b

Please sign in to comment.