mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-23 01:06:22 +00:00
parent
dbf15397e5
commit
07fd2cff93
1 changed files with 2 additions and 2 deletions
|
@ -9,7 +9,7 @@ class ActivityPub
|
||||||
def perform(site:, hostnames:, perform_remotely: true)
|
def perform(site:, hostnames:, perform_remotely: true)
|
||||||
# Crear las instancias que no existan todavía
|
# Crear las instancias que no existan todavía
|
||||||
hostnames.each do |hostname|
|
hostnames.each do |hostname|
|
||||||
ActivityPub::Instance.find_or_create_by(hostname: hostname)
|
ActivityPub::Instance.lock.find_or_create_by(hostname: hostname)
|
||||||
end
|
end
|
||||||
|
|
||||||
instances = ActivityPub::Instance.where(hostname: hostnames)
|
instances = ActivityPub::Instance.where(hostname: hostnames)
|
||||||
|
@ -20,7 +20,7 @@ class ActivityPub
|
||||||
instances.find_each do |instance|
|
instances.find_each do |instance|
|
||||||
# Esto bloquea cada una individualmente en la Social Inbox,
|
# Esto bloquea cada una individualmente en la Social Inbox,
|
||||||
# idealmente son pocas instancias las que aparecen.
|
# idealmente son pocas instancias las que aparecen.
|
||||||
site.instance_moderations.find_or_create_by(instance: instance)
|
site.instance_moderations.lock.find_or_create_by(instance: instance)
|
||||||
end
|
end
|
||||||
|
|
||||||
scope = site.instance_moderations.where(instance_id: instances.ids)
|
scope = site.instance_moderations.where(instance_id: instances.ids)
|
||||||
|
|
Loading…
Reference in a new issue