Skip to content

Commit

Permalink
yet another fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gildas-lormeau committed Feb 24, 2023
1 parent aeecfe9 commit f645ffa
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/core/zip-fs-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,15 +218,15 @@ class ZipDirectoryEntry extends ZipEntry {

clone(deepClone) {
const zipEntry = this;
const clone = new ZipDirectoryEntry(zipEntry.fs, zipEntry.name);
const clonedEntry = new ZipDirectoryEntry(zipEntry.fs, zipEntry.name);
if (deepClone) {
clone.children = zipEntry.children.map(child => {
clonedEntry.children = zipEntry.children.map(child => {
const clone = child.clone(deepClone);
clone.parent = zipEntry;
return clone;
return clonedEntry;
});
}
return clone;
return clonedEntry;
}

addDirectory(name) {
Expand Down

0 comments on commit f645ffa

Please sign in to comment.