Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d3e5842ff7 | ||
|
|
ce9bf45010 | ||
|
|
01f177a5ee |
@@ -197,12 +197,6 @@ func (a *apiServer) handleCreatePasteMultipart(w http.ResponseWriter, r *http.Re
|
|||||||
writeErrCode(w, 400, "burn_invalid", "burn_after_reads must be a positive number")
|
writeErrCode(w, 400, "burn_invalid", "burn_after_reads must be a positive number")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
// negative values are invalid too: same 400 burn_invalid shape
|
|
||||||
// as the JSON path (validate.go:92), identical message text.
|
|
||||||
if err := parseBurnAfterReads(n); err != nil {
|
|
||||||
writeErrCode(w, 400, "burn_invalid", err.Error())
|
|
||||||
return
|
|
||||||
}
|
|
||||||
p.BurnAfterReads = &n
|
p.BurnAfterReads = &n
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user