* insert table of contents if it is set either in the config file or in the frontmatter - frontmatter has priority */ -}}
          {{ $.Scratch.Set "pagetoc" .TableOfContents }}
          {{ if or (and (isset .Params "toc") (eq .Params.toc true)) (and (not (isset .Params "toc")) (eq .Site.Params.tableOfContents true)) }}
            {{ $.Scratch.Get "pagetoc" }}
          {{ end }}
          {{ .Content }}
        </div>
        {{ partial "post_footer.html" . }}
      </article>
    </div>
    {{ partial 