Skip to content

Commit 244796d

Browse files
committed
Accommodate both the preview and deployed site
1 parent 41eb94b commit 244796d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spec/_static/javascripts/version_dropdown.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function add_version_dropdown(json_loc, target_loc, text) {
2121
dropdown.appendChild(content);
2222
$.getJSON(json_loc, function(versions) {
2323
var currentURL = window.location.href;
24-
var path = currentURL.split("_site")[1];
24+
var path = currentURL.split(/_site|array_api/)[1];
2525
if (path) {
2626
path = path.split("/");
2727
path = path.slice(2, path.length);

0 commit comments

Comments
 (0)