Skip to content

Commit

Permalink
get rid of redundant (and incorrect) stats setting in mkdtemp
Browse files Browse the repository at this point in the history
  • Loading branch information
ProgrammerIn-wonderland committed Oct 30, 2024
1 parent d64d53e commit 1858169
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions src/api/LocalFS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -632,25 +632,6 @@ class LocalFS extends AFSProvider<LocalFSStats> {
// Replace 'XXXXXX' in the template with the random suffix
const newDir = template.replace("XXXXXX", randomSuffix);

// Add the new directory to stats
this.stats.set(newDir, {
dev: 1,
ino: Math.floor(Math.random() * 100000),
mode: 0o777,
nlink: 1,
uid: 1000,
gid: 1000,
rdev: 0,
size: 4096,
blksize: 4096,
blocks: 1,
atimeMs: Date.now(),
mtimeMs: Date.now(),
ctimeMs: Date.now(),
birthtimeMs: Date.now(),
isDirectory: true,
isFile: false,
});
this.promises.mkdir(newDir);
// Save the new stats
this.promises
Expand Down

0 comments on commit 1858169

Please sign in to comment.