Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions config/initializers/diaspora_federation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,17 @@

on :receive_entity do |entity, sender, recipient_id|
Person.by_account_identifier(sender).pod.try(:schedule_check_if_needed)
if User.exists?(recipient_id)
User.find(recipient_id).tap do |user|
next unless user&.person&.account_migration

Diaspora::Federation::Dispatcher.build(
user,
user.person&.account_migration,
subscribers: [Person.by_account_identifier(sender)]
).dispatch
end
end

case entity
when DiasporaFederation::Entities::AccountDeletion
Expand Down