Merge branch 'main' into glitch-soc/merge-upstream
Conflicts: - `.env.production.sample`: Upstream added new configuration options, uncommented by default. Commented them. - `Gemfile.lock`: Upstream updated dependencies textually close to glitch-soc-specific dependencies. Updated those upstream dependencies.
This commit is contained in:
@ -195,6 +195,10 @@ module AccountInteractions
|
||||
!following_anyone?
|
||||
end
|
||||
|
||||
def followed_by?(other_account)
|
||||
other_account.following?(self)
|
||||
end
|
||||
|
||||
def blocking?(other_account)
|
||||
block_relationships.where(target_account: other_account).exists?
|
||||
end
|
||||
|
@ -43,9 +43,7 @@ class Form::AccountBatch
|
||||
end
|
||||
|
||||
def remove_from_followers!
|
||||
current_account.passive_relationships.where(account_id: account_ids).find_each do |follow|
|
||||
reject_follow!(follow)
|
||||
end
|
||||
RemoveFromFollowersService.new.call(current_account, account_ids)
|
||||
end
|
||||
|
||||
def block_domains!
|
||||
@ -62,14 +60,6 @@ class Form::AccountBatch
|
||||
Account.where(id: account_ids)
|
||||
end
|
||||
|
||||
def reject_follow!(follow)
|
||||
follow.destroy
|
||||
|
||||
return unless follow.account.activitypub?
|
||||
|
||||
ActivityPub::DeliveryWorker.perform_async(Oj.dump(serialize_payload(follow, ActivityPub::RejectFollowSerializer)), current_account.id, follow.account.inbox_url)
|
||||
end
|
||||
|
||||
def approve!
|
||||
users = accounts.includes(:user).map(&:user)
|
||||
|
||||
|
Reference in New Issue
Block a user