diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-01-05 12:43:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-05 12:43:28 +0100 |
commit | a49d43d1121ac10f96d5a9cbf78112c707e7a59e (patch) | |
tree | ee311cf3d68d695f6cc6c69ce9e1b01c6ad4aeb4 /app/serializers/rest | |
parent | b17b2f25acc4d0cd4284835f28364451cb2fcd88 (diff) |
Add scheduled statuses (#9706)
Fix #340
Diffstat (limited to 'app/serializers/rest')
-rw-r--r-- | app/serializers/rest/scheduled_status_serializer.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/app/serializers/rest/scheduled_status_serializer.rb b/app/serializers/rest/scheduled_status_serializer.rb new file mode 100644 index 000000000..522991bcf --- /dev/null +++ b/app/serializers/rest/scheduled_status_serializer.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +class REST::ScheduledStatusSerializer < ActiveModel::Serializer + attributes :id, :scheduled_at + + has_many :media_attachments, serializer: REST::MediaAttachmentSerializer + + def id + object.id.to_s + end +end |