Test: アカウント削除時のブックマーク・スタンプなど削除のテスト (#276)
This commit is contained in:
parent
878936d4be
commit
2753d44563
6 changed files with 65 additions and 4 deletions
|
@ -42,7 +42,6 @@ module AccountAssociations
|
|||
|
||||
has_many :report_notes, dependent: :destroy
|
||||
has_many :custom_filters, inverse_of: :account, dependent: :destroy
|
||||
has_many :antennas, inverse_of: :account, dependent: :destroy
|
||||
has_many :antenna_accounts, inverse_of: :account, dependent: :destroy
|
||||
|
||||
# Moderation notes
|
||||
|
|
|
@ -11,6 +11,8 @@ class DeleteAccountService < BaseService
|
|||
antennas
|
||||
block_relationships
|
||||
blocked_by_relationships
|
||||
bookmark_categories
|
||||
circles
|
||||
conversation_mutes
|
||||
conversations
|
||||
custom_filters
|
||||
|
@ -39,6 +41,8 @@ class DeleteAccountService < BaseService
|
|||
account_notes
|
||||
account_pins
|
||||
aliases
|
||||
antenna_accounts
|
||||
circle_accounts
|
||||
conversation_mutes
|
||||
conversations
|
||||
custom_filters
|
||||
|
@ -225,6 +229,7 @@ class DeleteAccountService < BaseService
|
|||
|
||||
FeedManager.instance.clean_feeds!(:home, [@account.id])
|
||||
FeedManager.instance.clean_feeds!(:list, @account.owned_lists.pluck(:id))
|
||||
FeedManager.instance.clean_feeds!(:antenna, @account.antennas.pluck(:id))
|
||||
end
|
||||
|
||||
def purge_profile!
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue