Commit d3a84fe4 authored by Deimos's avatar Deimos

Fix issue if "most recent comment" not found

Not sure exactly how this can happen, but I've seen a few errors caused
by this.
parent 2d023cd6
......@@ -323,12 +323,14 @@
({{ pluralize(comments.num_top_level, "thread") }})
</dd>
<dt>Last comment posted</dt>
<dd>
<a href="{{ comments.most_recent_comment.permalink }}" data-js-hide-sidebar-no-preventdefault>
{{ adaptive_date_responsive(comments.most_recent_comment.created_time) }}
</a>
</dd>
{% if comments.most_recent_comment %}
<dt>Last comment posted</dt>
<dd>
<a href="{{ comments.most_recent_comment.permalink }}" data-js-hide-sidebar-no-preventdefault>
{{ adaptive_date_responsive(comments.most_recent_comment.created_time) }}
</a>
</dd>
{% endif %}
{% else %}
<dd>No comments yet</dd>
{% endif %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment