#71 フレンドサーバーにスタンプを送信
This commit is contained in:
parent
e16d8a00f3
commit
db98ef8a44
1 changed files with 9 additions and 0 deletions
|
@ -57,6 +57,7 @@ class ActivityPub::Activity::Like < ActivityPub::Activity
|
|||
NotifyService.new.call(@original_status.account, :emoji_reaction, reaction)
|
||||
forward_for_emoji_reaction
|
||||
relay_for_emoji_reaction
|
||||
relay_friend_for_emoji_reaction
|
||||
end
|
||||
rescue Seahorse::Client::NetworkingError
|
||||
nil
|
||||
|
@ -76,6 +77,14 @@ class ActivityPub::Activity::Like < ActivityPub::Activity
|
|||
end
|
||||
end
|
||||
|
||||
def relay_friend_for_emoji_reaction
|
||||
return unless @json['signature'].present? && @original_status.public_visibility?
|
||||
|
||||
ActivityPub::DeliveryWorker.push_bulk(FriendDomain.distributables.pluck(:inbox_url)) do |inbox_url|
|
||||
[Oj.dump(@json), @original_status.account.id, inbox_url]
|
||||
end
|
||||
end
|
||||
|
||||
def shortcode
|
||||
return @shortcode if defined?(@shortcode)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue