Skip to content

Commit 3f56555

Browse files
authored
Merge pull request processing#2153 from parteekcoder/download_fix
downloadzip-solved
2 parents 9c1ffc7 + 5f12155 commit 3f56555

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

server/controllers/project.controller.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,10 @@ function addFileToZip(file, files, zip, path = '') {
222222
const numChildFiles = file.children.filter((f) => f.fileType !== 'folder')
223223
.length;
224224
let childrenAdded = 0;
225-
225+
if (numChildFiles === 0) {
226+
zip.folder(file.name);
227+
resolve();
228+
}
226229
file.children.forEach(async (fileId) => {
227230
const childFile = files.find((f) => f.id === fileId);
228231

0 commit comments

Comments
 (0)