{{- if or (eq .Params.comments true) (and (ne .Params.comments false) (eq site.Params.comments.enable true)) -}}
    <section class="article discussion">
    {{- if gt (len site.DisqusShortname) 0 -}}
        {{- template "_internal/disqus.html" . -}}
    {{- else if ne site.Params.comments.utterances.repo "" -}}
        <script 
            src="https://utteranc.es/client.js" 
            repo="{{- site.Params.comments.utterances.repo }}"
            issue-term="{{ default "pathname" site.Params.comments.utterances.issueTerm }}"
            label="{{- default "" site.Params.comments.utterances.label -}}"
            theme="{{- default "github-light" site.Params.comments.utterances.theme -}}"
            crossorigin="anonymous" async>
        </script>
    {{- end -}}
    </section>
{{- end -}}