Add reaction limit to instance serializer

This commit is contained in:
Jeremy Kescher 2022-12-02 08:05:10 +01:00
parent 9ea349ea92
commit 3c84fc19d4
No known key found for this signature in database
GPG key ID: 80A419A7A613DFA4
2 changed files with 8 additions and 0 deletions

View file

@ -78,6 +78,10 @@ class REST::InstanceSerializer < ActiveModel::Serializer
translation: { translation: {
enabled: TranslationService.configured?, enabled: TranslationService.configured?,
}, },
reactions: {
max_reactions: StatusReactionValidator::LIMIT,
},
} }
end end

View file

@ -97,6 +97,10 @@ class REST::V1::InstanceSerializer < ActiveModel::Serializer
min_expiration: PollValidator::MIN_EXPIRATION, min_expiration: PollValidator::MIN_EXPIRATION,
max_expiration: PollValidator::MAX_EXPIRATION, max_expiration: PollValidator::MAX_EXPIRATION,
}, },
reactions: {
max_reactions: StatusReactionValidator::LIMIT,
},
} }
end end