DEV: Remove deprecated PostAction.remove_act method (#24126)

The PostAction.remove_act class method has been deprecated and replaced by PostActionDestroyer. It was marked for removal in version 2.9.0. This PR removes the method.
This commit is contained in:
Ted Johansson 2023-10-27 10:02:14 +08:00 committed by GitHub
parent 545e92039c
commit 3ad8e1fbde
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 10 deletions

View File

@ -136,16 +136,6 @@ class PostAction < ActiveRecord::Base
target_post.post_actions.each { |post_action| post_action.update_counters }
end
def self.remove_act(user, post, post_action_type_id)
Discourse.deprecate(
"PostAction.remove_act is deprecated. Use `PostActionDestroyer` instead.",
output_in_test: true,
drop_from: "2.9.0",
)
PostActionDestroyer.new(user, post, post_action_type_id).perform
end
def remove_act!(user)
trash!(user)
# NOTE: save is called to ensure all callbacks are called