闭社主体 forked from https://github.com/tootsuite/mastodon
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
295 B

  1. # frozen_string_literal: true
  2. class ActivityPub::UndoLikeSerializer < ActiveModel::Serializer
  3. attributes :type, :actor
  4. has_one :object, serializer: ActivityPub::LikeSerializer
  5. def type
  6. 'Undo'
  7. end
  8. def actor
  9. ActivityPub::TagManager.instance.uri_for(object.account)
  10. end
  11. end