From a407f6239461266dd5534358995348873fe93f99 Mon Sep 17 00:00:00 2001 From: Rodrigo Souto Date: Tue, 13 May 2014 18:28:10 -0300 Subject: [PATCH] Use top lovel comments count to consider displaying top and bottom post button --- app/views/content_viewer/view_page.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/content_viewer/view_page.html.erb b/app/views/content_viewer/view_page.html.erb index a1f10a4..25cba4a 100644 --- a/app/views/content_viewer/view_page.html.erb +++ b/app/views/content_viewer/view_page.html.erb @@ -80,7 +80,7 @@ <% end %> - <% if @page.accept_comments? && @comments_count > 1 %> + <% if @page.accept_comments? && @comments.count > 1 %> <%= link_to(_('Post a comment'), '#', :class => 'display-comment-form', :id => 'top-post-comment-button', :onclick => "jQuery('#page-comment-form .display-comment-form').first().click();") %> <%= hidden_field_tag("page_url", url_for(:controller=>'content_viewer', :action=>'view_page', :profile=>profile.identifier)) %> -- libgit2 0.21.2