Add searchability support
This commit is contained in:
parent
a2e674af51
commit
af20b1d2aa
43 changed files with 716 additions and 65 deletions
|
@ -7,13 +7,13 @@ class ActivityPub::ActorSerializer < ActivityPub::Serializer
|
|||
context :security
|
||||
|
||||
context_extensions :manually_approves_followers, :featured, :also_known_as,
|
||||
:moved_to, :property_value, :discoverable, :olm, :suspended
|
||||
:moved_to, :property_value, :discoverable, :olm, :suspended, :searchable_by
|
||||
|
||||
attributes :id, :type, :following, :followers,
|
||||
:inbox, :outbox, :featured, :featured_tags,
|
||||
:preferred_username, :name, :summary,
|
||||
:url, :manually_approves_followers,
|
||||
:discoverable, :published
|
||||
:discoverable, :published, :searchable_by
|
||||
|
||||
has_one :public_key, serializer: ActivityPub::PublicKeySerializer
|
||||
|
||||
|
@ -162,6 +162,10 @@ class ActivityPub::ActorSerializer < ActivityPub::Serializer
|
|||
object.created_at.midnight.iso8601
|
||||
end
|
||||
|
||||
def searchable_by
|
||||
ActivityPub::TagManager.instance.account_searchable_by(object)
|
||||
end
|
||||
|
||||
class CustomEmojiSerializer < ActivityPub::EmojiSerializer
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue