Le fixes part 1

This commit is contained in:
2023-10-19 16:50:58 -04:00
parent 0d7f9cac5f
commit 387cf6a6b2
4 changed files with 157 additions and 82 deletions

View File

@ -21,9 +21,10 @@ export async function onRequestPost(context: RequestContext) {
return jsonError("Forbidden", 403);
if (
context.request.headers
!context.request.headers
.get("content-type")
?.startsWith("multipart/form-data; boundary=")
?.toLowerCase()
.startsWith("multipart/form-data;")
)
return jsonError("Invalid content type", 400);