[38878] Fix condition in scrolling to wiki element nav

[OP#38878](https://community.openproject.org/wp/38878)
pull/9655/head
Oliver Günther 3 years ago
parent 91909bc31c
commit 68289ff849
No known key found for this signature in database
GPG Key ID: A3A8BDAD7C0C552C
  1. 2
      frontend/src/app/globals/tree-menu.ts

@ -37,7 +37,7 @@
if (selectedPage) {
const selected = $('[slug="' + selectedPage + '"]', tree);
selected.toggleClass('-selected', true);
if (selected.length > 1) {
if (selected.length > 0) {
selected[0].scrollIntoView();
}
}

Loading…
Cancel
Save