PostDisapproval: fix duplicate initialize_attributes definition.
This commit is contained in:
@@ -16,10 +16,6 @@ class PostDisapproval < ApplicationRecord
|
|||||||
self.user_id ||= CurrentUser.user.id
|
self.user_id ||= CurrentUser.user.id
|
||||||
end
|
end
|
||||||
|
|
||||||
def initialize_attributes
|
|
||||||
self.user_id ||= CurrentUser.user.id
|
|
||||||
end
|
|
||||||
|
|
||||||
def self.prune!
|
def self.prune!
|
||||||
PostDisapproval.where("post_id in (select _.post_id from post_disapprovals _ where _.created_at < ?)", DELETION_THRESHOLD.ago).delete_all
|
PostDisapproval.where("post_id in (select _.post_id from post_disapprovals _ where _.created_at < ?)", DELETION_THRESHOLD.ago).delete_all
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user