Skip to content

Commit

Permalink
replace unlink with rm
Browse files Browse the repository at this point in the history
  • Loading branch information
felabr committed Jul 16, 2024
1 parent 1bd211d commit 3c6ae8b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion projects/core/src/utils/file-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export function withFileLock<T>(filePath: string, fn: () => T): T {
fs.writeFileSync(lockFilePath, '');
return fn();
} finally {
if (fs.existsSync(lockFilePath)) fs.unlinkSync(lockFilePath);
if (fs.existsSync(lockFilePath)) fs.rmSync(lockFilePath, { force: true });
}
}

Expand Down

0 comments on commit 3c6ae8b

Please sign in to comment.