1
0
mirror of https://github.com/lus/pasty.git synced 2023-08-10 21:13:09 +03:00

Fix error

This commit is contained in:
Lukas SP 2020-08-23 00:45:56 +02:00
parent e297a5c2b4
commit 0f90b267c7

View File

@ -105,7 +105,7 @@ func v1DeletePaste(ctx *fasthttp.RequestCtx) {
// Unmarshal the body // Unmarshal the body
values := make(map[string]string) values := make(map[string]string)
err := json.Unmarshal(ctx.PostBody(), &values) err = json.Unmarshal(ctx.PostBody(), &values)
if err != nil { if err != nil {
ctx.SetStatusCode(fasthttp.StatusBadRequest) ctx.SetStatusCode(fasthttp.StatusBadRequest)
ctx.SetBodyString("invalid request body") ctx.SetBodyString("invalid request body")