mirror of
https://git.pleroma.social/sjw/pleroma.git
synced 2024-12-25 06:15:09 +01:00
Fix preview not being usable in form data
This commit is contained in:
parent
0cb94cfa94
commit
79cb34a4b0
@ -47,6 +47,6 @@ Has these additional fields under the `pleroma` object:
|
||||
|
||||
## POST `/api/v1/statuses`
|
||||
|
||||
Additional parameters can be added to the JSON body:
|
||||
Additional parameters can be added to the JSON body/Form data:
|
||||
|
||||
- `preview`: boolean, if set to `true` the post won't be actually posted, but the status entitiy would still be rendered back. This could be useful for previewing rich text/custom emoji, for example.
|
||||
|
@ -180,7 +180,7 @@ defmodule Pleroma.Web.CommonAPI do
|
||||
object: object,
|
||||
additional: %{"cc" => cc, "directMessage" => visibility == "direct"}
|
||||
},
|
||||
data["preview"] || false
|
||||
Pleroma.Web.ControllerHelper.truthy_param?(data["preview"]) || false
|
||||
)
|
||||
|
||||
res
|
||||
|
Loading…
Reference in New Issue
Block a user