5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2025-03-15 03:48:16 +00:00

Merge branch 'issue-15109-1' of https://0xacab.org/sutty/sutty into production.panel.sutty.nl

This commit is contained in:
Sutty 2024-03-07 20:47:06 +00:00
commit ea3f399532

View file

@ -3,7 +3,7 @@
# Algunes quedaron como genéricxs
class RemoveActorModerations2 < ActiveRecord::Migration[6.1]
def up
actor_uris = ActivityPub::Activity.where(type: 'ActivityPub::Activity::Delete').distinct.pluck(Arel.sql("content->>'object'"))
actor_uris = ActivityPub::Activity.unscope(:order).where(type: 'ActivityPub::Activity::Delete').distinct.pluck(Arel.sql("content->>'object'"))
actor_ids = ActivityPub::Actor.where(uri: actor_uris).ids
ActorModeration.where(actor_id: actor_ids).remove_all!