Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/azmelanar/hugo-theme-pixyll.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElias Peterson <elias.peterson@gmail.com>2015-03-15 23:55:02 +0300
committerElias Peterson <elias.peterson@gmail.com>2015-03-15 23:55:02 +0300
commit2dc8ba77ce036663233b807c962e1319632eb683 (patch)
tree384191ffc944c84649b6ed4c2cb24922904fd9a3
parentb460512963c290f004cfe78af3adcd3379048f03 (diff)
Only render comments if disqus_shortname is set
If the "disqus_shortname" Site Parameter isn't set, don't render the disqus-related markup in the comments partial.
-rw-r--r--layouts/partials/comments.html2
1 files changed, 2 insertions, 0 deletions
diff --git a/layouts/partials/comments.html b/layouts/partials/comments.html
index 5cd4168..a958bf9 100644
--- a/layouts/partials/comments.html
+++ b/layouts/partials/comments.html
@@ -1,3 +1,4 @@
+{{ if isset .Site.Params "disqus_shortname" }}
<div id="disqus_thread">
<script type="text/javascript">
var disqus_shortname = "{{ .Site.Params.disqus_shortname }}";
@@ -10,3 +11,4 @@
})();
</script>
</div>
+{{ end }}