From 5100a62fc07f42bbea7da0b51d3ea191261b51ab Mon Sep 17 00:00:00 2001 From: Guo Xiang Tan Date: Mon, 25 Jun 2018 22:10:57 +0800 Subject: [PATCH] FIX: Megatopics forced into summary mode when loading posts. --- lib/topic_view.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/topic_view.rb b/lib/topic_view.rb index 90d55d04cbc..20ee45b3db7 100644 --- a/lib/topic_view.rb +++ b/lib/topic_view.rb @@ -51,6 +51,7 @@ class TopicView self.instance_variable_set("@#{key}".to_sym, value) end + @_post_number = @post_number.dup @post_number = [@post_number.to_i, 1].max @page = [@page.to_i, 1].max @@ -490,7 +491,7 @@ class TopicView # Filters if @filter == 'summary' || - ((@post_number.blank? || @post_number.to_i == 1) && force_summary_mode?) + ((@_post_number.blank? || @_post_number.to_i == 1) && force_summary_mode?) @filtered_posts = @filtered_posts.summary(@topic.id) @contains_gaps = true unless force_summary_mode?