mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-22 15:46:21 +00:00
fix: typo
closes #15792 closes #15793 closes #15794 closes #15795 closes #15796 closes #15797 closes #15798 closes #15799 closes #15800 closes #15801 closes #15802 closes #15803 closes #15804 closes #15805 closes #15806 closes #15807 closes #15808 closes #15809 closes #15810 closes #15811 closes #15812 closes #15813 closes #15814 closes #15815 closes #15816 closes #15817 closes #15818
This commit is contained in:
parent
07fd2cff93
commit
366494b615
1 changed files with 2 additions and 2 deletions
|
@ -94,7 +94,7 @@ class ActivityPub
|
||||||
.type_from(original_activity)
|
.type_from(original_activity)
|
||||||
.lock
|
.lock
|
||||||
.find_or_initialize_by(uri: original_activity[:id], activity_pub: activity_pub, actor: actor).tap do |a|
|
.find_or_initialize_by(uri: original_activity[:id], activity_pub: activity_pub, actor: actor).tap do |a|
|
||||||
a.lock! if o.persisted?
|
a.lock! if a.persisted?
|
||||||
a.content = original_activity.dup
|
a.content = original_activity.dup
|
||||||
a.content[:object] = object.uri
|
a.content[:object] = object.uri
|
||||||
a.save!
|
a.save!
|
||||||
|
@ -107,7 +107,7 @@ class ActivityPub
|
||||||
# @return [Actor]
|
# @return [Actor]
|
||||||
def actor
|
def actor
|
||||||
@actor ||= ::ActivityPub::Actor.lock.find_or_initialize_by(uri: original_activity[:actor]).tap do |a|
|
@actor ||= ::ActivityPub::Actor.lock.find_or_initialize_by(uri: original_activity[:actor]).tap do |a|
|
||||||
a.lock! if o.persisted?
|
a.lock! if a.persisted?
|
||||||
|
|
||||||
unless a.instance
|
unless a.instance
|
||||||
a.instance = ::ActivityPub::Instance.lock.find_or_create_by(hostname: URI.parse(a.uri).hostname)
|
a.instance = ::ActivityPub::Instance.lock.find_or_create_by(hostname: URI.parse(a.uri).hostname)
|
||||||
|
|
Loading…
Reference in a new issue