Skip to content

Commit 12279ac

Browse files
committed
chore: Remove one extra jQuery statement
1 parent dfcc6be commit 12279ac

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

_assets/js/toc-base.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
function animateScrolling(hash) {
22
var isApiSection = $("article.api-reference").length == 1;
3-
var hasBreadCrumbs = $("p.breadcrumbs").length == 1 && $("p.breadcrumbs").text().trim() != "";
3+
var breadCrumbsElement = $("p.breadcrumbs");
4+
var hasBreadCrumbs = breadCrumbsElement.length == 1 && breadCrumbsElement.text().trim() != "";
45
var currentScrollTop = $(window).scrollTop();
56
var offset = $(hash).offset() || { top: currentScrollTop };
67

0 commit comments

Comments
 (0)