diff options
Diffstat (limited to 'app/serializers/activitypub/activity_serializer.rb')
-rw-r--r-- | app/serializers/activitypub/activity_serializer.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/app/serializers/activitypub/activity_serializer.rb b/app/serializers/activitypub/activity_serializer.rb index df399211c..50c4f6a04 100644 --- a/app/serializers/activitypub/activity_serializer.rb +++ b/app/serializers/activitypub/activity_serializer.rb @@ -5,6 +5,7 @@ class ActivityPub::ActivitySerializer < ActiveModel::Serializer has_one :proper, key: :object, serializer: ActivityPub::NoteSerializer, unless: :announce? attribute :proper_uri, key: :object, if: :announce? + attribute :atom_uri, if: :announce? def id ActivityPub::TagManager.instance.activity_uri_for(object) @@ -34,6 +35,10 @@ class ActivityPub::ActivitySerializer < ActiveModel::Serializer ActivityPub::TagManager.instance.uri_for(object.proper) end + def atom_uri + OStatus::TagManager.instance.uri_for(object) + end + def announce? object.reblog? end |