fix minor issue in navbar
Some checks are pending
ci/woodpecker/push/publish Pipeline is pending

This commit is contained in:
Mylloon 2023-12-10 19:11:09 +01:00
parent 61015a2536
commit 7fc3f95dd5
Signed by: Anri
GPG key ID: A82D63DFF8D1317F

View file

@ -65,20 +65,17 @@ const deepestNodeOpened = (path, options) => {
// Iterate over possible options
for (let i = 0; i < options.length; ++i) {
// If the directory and the current path match
if (path[0] === options[i].firstChild.nodeValue) {
if (decodeURI(path[0]) === options[i].firstChild.nodeValue) {
if (path.length === 1) {
// We found it
return options[i];
}
// Continue the search
let returned_value = deepestNodeOpened(
return deepestNodeOpened(
path.slice(1),
options[i].querySelector("ul").childNodes
);
if (returned_value) {
return returned_value;
}
}
}
};