mirror of
https://github.com/discourse/discourse.git
synced 2025-06-04 22:34:43 +08:00
Merge pull request #3033 from verdi327/account_for_deleted_topic
[bug fix] Use with_deleted when looking up soft deleted topics for recovery
This commit is contained in:
@ -54,8 +54,9 @@ class PostDestroyer
|
||||
elsif @user.staff? || @user.id == @post.user_id
|
||||
user_recovered
|
||||
end
|
||||
@post.topic.recover! if @post.post_number == 1
|
||||
@post.topic.update_statistics
|
||||
topic = Topic.with_deleted.find @post.topic_id
|
||||
topic.recover! if @post.post_number == 1
|
||||
topic.update_statistics
|
||||
end
|
||||
|
||||
def staff_recovered
|
||||
|
Reference in New Issue
Block a user