~cytrogen/masto-fe

ref: 5ed72f668f24860b355a74d8325f041426232dfe masto-fe/app/services/activitypub/fetch_remote_poll_service.rb -rw-r--r-- 338 bytes
5ed72f66 — Claire Merge commit 'b90383d07388fe8513e59a6deb1a2391146c6561' into glitch-soc/merge-upstream 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
# frozen_string_literal: true

class ActivityPub::FetchRemotePollService < BaseService
  include JsonLdHelper

  def call(poll, on_behalf_of = nil)
    json = fetch_resource(poll.status.uri, true, on_behalf_of)

    return unless supported_context?(json)

    ActivityPub::ProcessStatusUpdateService.new.call(poll.status, json)
  end
end