Commit 24c27953cd5c6f2dbcaa57b47110e5dd83b05a77
1 parent
f4c6569d
Exists in
theme-brasil-digital-from-staging
and in
9 other branches
Fix view page when comments_count was not defined
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
app/views/content_viewer/view_page.html.erb
... | ... | @@ -72,7 +72,7 @@ |
72 | 72 | |
73 | 73 | <div class="comments" id="comments_list"> |
74 | 74 | |
75 | - <% if @page.accept_comments? || @comments_count > 0 %> | |
75 | + <% if @page.accept_comments? || (@comments_count.present? && @comments_count > 0) %> | |
76 | 76 | <h3 <%= 'class="no-comments-yet"' if @comments_count == 0 %>> |
77 | 77 | <%= display_number_of_comments(@comments_count) %> |
78 | 78 | </h3> | ... | ... |