Commit 45d9194b49c6284d307c2a8aaaff58a0ed54db88
1 parent
5ff64d4f
Exists in
master
and in
29 other branches
Fix visualization of forum posts
Showing
1 changed file
with
2 additions
and
2 deletions
Show diff stats
app/controllers/public/content_viewer_controller.rb
... | ... | @@ -31,8 +31,8 @@ class ContentViewerController < ApplicationController |
31 | 31 | |
32 | 32 | if request.post? && @page.forum? |
33 | 33 | process_forum_terms_of_use(user, params[:terms_accepted]) |
34 | - elsif is_a_forum_topic?(@page) | |
35 | - redirect_to @page.parent.url unless @page.parent.agrees_with_terms?(user) | |
34 | + elsif is_a_forum_topic?(@page) && !@page.parent.agrees_with_terms?(user) | |
35 | + redirect_to @page.parent.url | |
36 | 36 | return |
37 | 37 | end |
38 | 38 | ... | ... |