diff --git a/lib/guardian/post_guardian.rb b/lib/guardian/post_guardian.rb index 154f8c8c67d..4e6c579540b 100644 --- a/lib/guardian/post_guardian.rb +++ b/lib/guardian/post_guardian.rb @@ -20,7 +20,7 @@ module PostGuardian not(is_flag || already_taken_this_action) && # nothing except flagging on archived topics - not(post.topic.archived?) && + not(post.topic.try(:archived?)) && # nothing except flagging on deleted posts not(post.trashed?) &&