Don't load Disqus script on pages that don't require it

- Was loading Disqus in the script.html include even when a shortname wasn't specified
This commit is contained in:
Michael Rose 2014-07-10 14:26:11 -04:00
parent 90f341d5ea
commit 574c644bdb
2 changed files with 2 additions and 2 deletions

View file

@ -54,4 +54,4 @@
})();
</script>
{% endif %}
{% if page.comments %}{% include disqus_comments.html %}{% endif %}
{% if site.disqus_shortname %}{% if page.comments %}{% include disqus_comments.html %}{% endif %}{% endif %}

View file

@ -41,7 +41,7 @@
{% endif %}
<span class="entry-date date published"><time datetime="{{ page.date | date_to_xmlschema }}"><i class="icon-calendar-empty"></i> {{ page.date | date: "%B %d, %Y" }}</time></span>
{% if page.modified %}<span class="entry-date date modified"><time datetime="{{ page.modified }}"><i class="icon-pencil"></i> {{ page.modified | date: "%B %d, %Y" }}</time></span>{% endif %}
{% if site.disqus_shortname and page.comments %}<span class="entry-comments"><i class="icon-comment-alt"></i> <a href="#disqus_thread">Comment</a></span>{% endif %}
{% if site.disqus_shortname %}{% if page.comments %}<span class="entry-comments"><i class="icon-comment-alt"></i> <a href="#disqus_thread">Comment</a></span>{% endif %}{% endif %}
<span><a href="{{ site.url }}{{ page.url }}" rel="bookmark" title="{{ page.title }}"><i class="icon-link"></i> Permalink</a></span>
{% if page.share %}
<span class="social-share-facebook">