mirror of
https://github.com/mastodon/mastodon.git
synced 2024-12-23 18:02:59 +01:00
13 lines
452 B
Ruby
13 lines
452 B
Ruby
# frozen_string_literal: true
|
|
|
|
class ActivityPub::PrepareFollowersSynchronizationService < BaseService
|
|
include JsonLdHelper
|
|
|
|
def call(account, params)
|
|
@account = account
|
|
|
|
return if params['collectionId'] != @account.followers_url || non_matching_uri_hosts?(@account.uri, params['url']) || @account.local_followers_hash == params['digest']
|
|
|
|
ActivityPub::FollowersSynchronizationWorker.perform_async(@account.id, params['url'])
|
|
end
|
|
end
|