Skip to content

Commit d32d91b

Browse files
authored
Update sidebar.js
fix bug docsifyjs#1110
1 parent 957609a commit d32d91b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/core/event/sidebar.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ export function collapse(el) {
3838
dom.on(el, 'click', ({ target }) => {
3939
if (
4040
target.nodeName === 'A' &&
41-
target.nextSibling &&
41+
target.nextSibling &&
42+
target.nextSibling.classList &&
4243
target.nextSibling.classList.contains('app-sub-sidebar')
4344
) {
4445
dom.toggleClass(target.parentNode, 'collapse');

0 commit comments

Comments
 (0)