Merge branch 'fix/2498-expires_in-scheduled-posts' into 'develop'
expires_in in scheduled status params Closes #2498 See merge request pleroma/pleroma!3315
This commit is contained in:
commit
840686ecd5
6 changed files with 40 additions and 4 deletions
|
|
@ -30,7 +30,8 @@ defmodule Pleroma.Web.ApiSpec.Schemas.ScheduledStatus do
|
|||
visibility: %Schema{allOf: [VisibilityScope], nullable: true},
|
||||
scheduled_at: %Schema{type: :string, format: :"date-time", nullable: true},
|
||||
poll: StatusOperation.poll_params(),
|
||||
in_reply_to_id: %Schema{type: :string, nullable: true}
|
||||
in_reply_to_id: %Schema{type: :string, nullable: true},
|
||||
expires_in: %Schema{type: :integer, nullable: true}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
@ -46,7 +47,8 @@ defmodule Pleroma.Web.ApiSpec.Schemas.ScheduledStatus do
|
|||
scheduled_at: nil,
|
||||
poll: nil,
|
||||
idempotency: nil,
|
||||
in_reply_to_id: nil
|
||||
in_reply_to_id: nil,
|
||||
expires_in: nil
|
||||
},
|
||||
media_attachments: [Attachment.schema().example]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,7 +37,8 @@ defmodule Pleroma.Web.MastodonAPI.ScheduledActivityView do
|
|||
visibility: params["visibility"],
|
||||
scheduled_at: params["scheduled_at"],
|
||||
poll: params["poll"],
|
||||
in_reply_to_id: params["in_reply_to_id"]
|
||||
in_reply_to_id: params["in_reply_to_id"],
|
||||
expires_in: params["expires_in"]
|
||||
}
|
||||
|> Pleroma.Maps.put_if_present(:media_ids, params["media_ids"])
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue