0
0
Fork 0

Make follow requests federate

This commit is contained in:
Eugen Rochko 2017-02-11 02:12:05 +01:00
parent d551e43a9b
commit 149887a0ff
25 changed files with 148 additions and 61 deletions

View file

@ -1,6 +1,8 @@
# frozen_string_literal: true
class ProcessMentionsService < BaseService
include StreamEntryRenderer
# Scan status for mentions and fetch remote mentioned users, create
# local mention pointers, send Salmon notifications to mentioned
# remote users
@ -33,7 +35,7 @@ class ProcessMentionsService < BaseService
if mentioned_account.local?
NotifyService.new.call(mentioned_account, mention)
else
NotificationWorker.perform_async(status.stream_entry.id, mentioned_account.id)
NotificationWorker.perform_async(stream_entry_to_xml(status.stream_entry), status.account_id, mentioned_account.id)
end
end
end