Merge remote-tracking branch 'parent/main' into kb_migration

This commit is contained in:
KMY 2023-08-25 12:19:55 +09:00
commit fbb82b740b
72 changed files with 722 additions and 246 deletions

View file

@ -8,13 +8,13 @@ class ActivityPub::ActorSerializer < ActivityPub::Serializer
context_extensions :manually_approves_followers, :featured, :also_known_as,
:moved_to, :property_value, :discoverable, :olm, :suspended, :searchable_by, :subscribable_by,
:other_setting, :memorial
:other_setting, :memorial, :indexable
attributes :id, :type, :following, :followers,
:inbox, :outbox, :featured, :featured_tags,
:preferred_username, :name, :summary,
:url, :manually_approves_followers,
:discoverable, :published, :searchable_by, :subscribable_by, :other_setting, :memorial
:discoverable, :indexable, :published, :memorial, :searchable_by, :subscribable_by, :other_setting
has_one :public_key, serializer: ActivityPub::PublicKeySerializer
@ -107,6 +107,10 @@ class ActivityPub::ActorSerializer < ActivityPub::Serializer
object.suspended? ? false : (object.discoverable || false)
end
def indexable
object.suspended? ? false : (object.indexable || false)
end
def name
object.suspended? ? object.username : (object.display_name.presence || object.username)
end