From 03c72653c5d18fa416726621a106ec9398cd11d3 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 4 Nov 2021 14:20:43 +0100 Subject: [PATCH] fix uploaded directory name --- packages/website/src/components/Uploader/UploaderElement.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/website/src/components/Uploader/UploaderElement.js b/packages/website/src/components/Uploader/UploaderElement.js index 86dd2ada..70557b63 100644 --- a/packages/website/src/components/Uploader/UploaderElement.js +++ b/packages/website/src/components/Uploader/UploaderElement.js @@ -85,7 +85,7 @@ export default function UploaderElement({ onUploadStateChange, upload }) { if (upload.mode === "directory") { const files = upload.file.files; const directory = files.reduce((acc, file) => ({ ...acc, [getRelativeFilePath(file)]: file }), {}); - const name = encodeURIComponent(upload.name); + const name = encodeURIComponent(upload.file.name); response = await client.uploadDirectory(directory, name, { onUploadProgress }); } else {