mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-22 19:26:21 +00:00
fixup! fix: no ignorar ningún evento
This commit is contained in:
parent
32042f32e2
commit
40edccf8bb
4 changed files with 12 additions and 4 deletions
|
@ -12,7 +12,6 @@ class ActivityPub < ApplicationRecord
|
|||
IGNORED_STATES = %i[removed]
|
||||
|
||||
include AASM
|
||||
include AasmEventsConcern
|
||||
|
||||
belongs_to :instance
|
||||
belongs_to :site
|
||||
|
@ -91,6 +90,9 @@ class ActivityPub < ApplicationRecord
|
|||
end
|
||||
end
|
||||
|
||||
# Definir eventos en masa
|
||||
include AasmEventsConcern
|
||||
|
||||
def reject_remotely!
|
||||
raise unless site.social_inbox.inbox.reject(id: object.uri).ok?
|
||||
end
|
||||
|
|
|
@ -6,7 +6,6 @@ class ActivityPub
|
|||
IGNORED_STATES = []
|
||||
|
||||
include AASM
|
||||
include AasmEventsConcern
|
||||
|
||||
aasm do
|
||||
state :waiting, initial: true
|
||||
|
@ -26,6 +25,9 @@ class ActivityPub
|
|||
end
|
||||
end
|
||||
|
||||
# Definir eventos en masa
|
||||
include AasmEventsConcern
|
||||
|
||||
belongs_to :actor
|
||||
belongs_to :site
|
||||
|
||||
|
|
|
@ -6,7 +6,6 @@ class ActorModeration < ApplicationRecord
|
|||
IGNORED_STATES = %i[removed]
|
||||
|
||||
include AASM
|
||||
include AasmEventsConcern
|
||||
|
||||
belongs_to :site
|
||||
belongs_to :remote_flag, optional: true, class_name: 'ActivityPub::RemoteFlag'
|
||||
|
@ -74,6 +73,9 @@ class ActorModeration < ApplicationRecord
|
|||
end
|
||||
end
|
||||
|
||||
# Definir eventos en masa
|
||||
include AasmEventsConcern
|
||||
|
||||
def pause_remotely!
|
||||
raise unless
|
||||
actor.mention &&
|
||||
|
|
|
@ -6,7 +6,6 @@ class InstanceModeration < ApplicationRecord
|
|||
IGNORED_STATES = []
|
||||
|
||||
include AASM
|
||||
include AasmEventsConcern
|
||||
|
||||
belongs_to :site
|
||||
belongs_to :instance, class_name: 'ActivityPub::Instance'
|
||||
|
@ -51,6 +50,9 @@ class InstanceModeration < ApplicationRecord
|
|||
end
|
||||
end
|
||||
|
||||
# Definir eventos en masa
|
||||
include AasmEventsConcern
|
||||
|
||||
# @return [Array<String>]
|
||||
def actor_ids
|
||||
ActivityPub::Actor.where(instance_id: self.instance_id).ids
|
||||
|
|
Loading…
Reference in a new issue