Skip to content

Commit

Permalink
Use lstat
Browse files Browse the repository at this point in the history
  • Loading branch information
hugoalh committed Dec 23, 2024
1 parent 0102e59 commit ecfdd7c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions _payload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -389,8 +389,8 @@ export async function resolveFiles(files: string[], glob: boolean): Promise<Form
if (pathIsAbsolute(file)) {
throw new Error(`\`${file}\` is not a relative file path!`);
}
const fileStat: Deno.FileInfo = await Deno.stat(pathJoin(workspace, file));
if (!fileStat.isFile) {
const fileStatL: Deno.FileInfo = await Deno.lstat(pathJoin(workspace, file));
if (!fileStatL.isFile) {
throw new Error(`\`${file}\` is not a file!`);
}
}))).map((fileStat: PromiseSettledResult<void>): unknown => {
Expand Down

0 comments on commit ecfdd7c

Please sign in to comment.