FIX: Resetting bump date shouldn't fail when first post is hidden

This commit is contained in:
Gerhard Schlager 2018-12-21 17:37:32 +01:00
parent fbd92916e5
commit 126be6c478
1 changed files with 1 additions and 1 deletions

View File

@ -1357,7 +1357,7 @@ class Topic < ActiveRecord::Base
user_deleted: false,
hidden: false,
post_type: Post.types[:regular]
).last
).last || first_post
update!(bumped_at: post.created_at)
end