From 31c66ae3cdc12a13a7c767e0eed29de9cfb9f5a9 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Sun, 18 Dec 2022 16:00:34 +0000 Subject: [PATCH] Server: Fixes #7463: Fixed regression introduced by form-parse lib update --- packages/server/src/routes/api/items.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/server/src/routes/api/items.ts b/packages/server/src/routes/api/items.ts index 5099bf7464..61efc62b19 100644 --- a/packages/server/src/routes/api/items.ts +++ b/packages/server/src/routes/api/items.ts @@ -38,7 +38,7 @@ export async function putItemContents(path: SubPath, ctx: AppContext, isBatch: b if (totalSize > batchMaxSize) throw new ErrorPayloadTooLarge(`Size of items (${formatBytes(totalSize)}) is over the limit (${formatBytes(batchMaxSize)})`); } else { - const filePath = parsedBody?.files?.file ? parsedBody.files.file.path : null; + const filePath = parsedBody?.files?.file ? parsedBody.files.file.filepath : null; try { const buffer = filePath ? await fs.readFile(filePath) : Buffer.alloc(0);