Skip to content

Commit

Permalink
toc: fix display when empty matcornic#469
Browse files Browse the repository at this point in the history
  • Loading branch information
McShelby committed Feb 10, 2023
1 parent 0cc5ff2 commit 7252f82
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/partials/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
{{- $defaultDisableToc := .Site.Params.disableToc | default false }}
{{- $currentDisableToc := .Params.disableToc | default $defaultDisableToc }}
{{- $toc_content := partial "toc.html" . }}
{{- $hastoc := not (eq 0 (int (len ($toc_content | plainify)))) }}
{{- $hastoc := not (eq 0 (int (len (trim ($toc_content | plainify) "\n\t ")))) }}
{{- $toc := and $hastoc (not $currentDisableToc) (eq $outputFormat "html") }}
<div id="breadcrumbs">
<span id="sidebar-toggle-span">
Expand Down

0 comments on commit 7252f82

Please sign in to comment.