Fix: Actually get rid of the notice when posting the first comment.

This commit is contained in:
flash 2018-10-08 15:28:19 +02:00
parent a89c634799
commit a103701d6a

View file

@ -175,7 +175,7 @@
{{ comments_entry(comment, 1, category, user, perms) }}
{% endfor %}
{% else %}
<div class="comments__none">
<div class="comments__none" id="_no_comments_notice_{{ category.category_id }}">
There are no comments yet.
</div>
{% endif %}
@ -489,6 +489,9 @@
parent.insertBefore(commentElement, parent.firstElementChild);
timeago().render(commentTime);
var placeholder = document.getElementById('_no_comments_notice_' + comment.category_id);
placeholder.parentNode.removeChild(placeholder);
}
</script>
{% endif %}