0
0
Fork 0

Send one Delete of Actor in ActivityPub when account is suspended (#6172)

This commit is contained in:
Eugen Rochko 2018-01-04 14:40:49 +01:00 committed by GitHub
parent 3bee0996c5
commit 02ba03d6db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 35 additions and 37 deletions

View file

@ -0,0 +1,22 @@
# frozen_string_literal: true
class ActivityPub::DeleteActorSerializer < ActiveModel::Serializer
attributes :id, :type, :actor
attribute :virtual_object, key: :object
def id
[ActivityPub::TagManager.instance.uri_for(object), '#delete'].join
end
def type
'Delete'
end
def actor
ActivityPub::TagManager.instance.uri_for(object)
end
def virtual_object
actor
end
end