1
0
Fork 0
forked from gitea/nas

Merge remote-tracking branch 'parent/main' into upstream-20240716

This commit is contained in:
KMY 2024-07-16 09:01:12 +09:00
commit adee1645a3
203 changed files with 1707 additions and 1067 deletions

View file

@ -3,6 +3,8 @@
class REST::NotificationSerializer < ActiveModel::Serializer
attributes :id, :type, :created_at, :group_key
attribute :filtered, if: :filtered?
belongs_to :from_account, key: :account, serializer: REST::AccountSerializer
belongs_to :target_status, key: :status, if: :status_type?, serializer: REST::StatusSerializer
belongs_to :report, if: :report_type?, serializer: REST::ReportSerializer
@ -46,4 +48,6 @@ class REST::NotificationSerializer < ActiveModel::Serializer
def moderation_warning_event?
object.type == :moderation_warning
end
delegate :filtered?, to: :object
end