mirror of
https://github.com/yingziwu/mastodon.git
synced 2026-02-04 03:25:14 +00:00
Merge commit from fork
This commit is contained in:
parent
6f9b32b137
commit
9a25b12f0c
2 changed files with 4 additions and 1 deletions
|
|
@ -30,7 +30,8 @@ class ActivityPub::Activity::Update < ActivityPub::Activity
|
||||||
@status = Status.find_by(uri: object_uri, account_id: @account.id)
|
@status = Status.find_by(uri: object_uri, account_id: @account.id)
|
||||||
|
|
||||||
# Ignore updates for old unknown objects, since those are updates we are not interested in
|
# Ignore updates for old unknown objects, since those are updates we are not interested in
|
||||||
return if @status.nil? && object_too_old?
|
# Also ignore unknown objects from suspended users for the same reasons
|
||||||
|
return if @status.nil? && (@account.suspended? || object_too_old?)
|
||||||
|
|
||||||
# We may be getting `Create` and `Update` out of order
|
# We may be getting `Create` and `Update` out of order
|
||||||
@status ||= ActivityPub::Activity::Create.new(@json, @account, **@options).perform
|
@status ||= ActivityPub::Activity::Create.new(@json, @account, **@options).perform
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,8 @@ class FanOutOnWriteService < BaseService
|
||||||
@account = status.account
|
@account = status.account
|
||||||
@options = options
|
@options = options
|
||||||
|
|
||||||
|
return if @status.proper.account.suspended?
|
||||||
|
|
||||||
check_race_condition!
|
check_race_condition!
|
||||||
warm_payload_cache!
|
warm_payload_cache!
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue