Rename :poll to :preloadable_poll and :owned_poll to :poll on Status (#10401)
Also, fix some n+1 queries Resolve #10365
This commit is contained in:
parent
f46f67d984
commit
f1bc90ab50
15 changed files with 45 additions and 43 deletions
|
@ -23,8 +23,8 @@ class ActivityPub::Activity::Update < ActivityPub::Activity
|
|||
return reject_payload! if invalid_origin?(@object['id'])
|
||||
|
||||
status = Status.find_by(uri: object_uri, account_id: @account.id)
|
||||
return if status.nil? || status.poll.nil?
|
||||
return if status.nil? || status.preloadable_poll.nil?
|
||||
|
||||
ActivityPub::ProcessPollService.new.call(status.poll, @object)
|
||||
ActivityPub::ProcessPollService.new.call(status.preloadable_poll, @object)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue