posts: fix error on post index page when search count times out in safe mode
Fix a nil deference error on the post index page. This happened when performing a single tag search in safe mode and calculating the number of search results timed out.
This commit is contained in:
@@ -201,6 +201,7 @@ class PostQuery
|
||||
end
|
||||
|
||||
concerning :CountMethods do
|
||||
# @return [Integer, nil] The number of posts returned by the search, or nil on timeout.
|
||||
def post_count
|
||||
@post_count ||= fast_count
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user