mirror of
https://github.com/denoland/deno.git
synced 2025-03-04 01:44:26 -05:00
fix(ext/fs): fix boolean checks in JS parser (#19586)
This fixes a bug in file metadata parsing logic, which now properly evaluates boolean fields when forwarding for atime / mtime / birthtime values. Ref: https://github.com/denoland/deploy_feedback/issues/409
This commit is contained in:
parent
dda0f1c343
commit
76f85a783e
1 changed files with 3 additions and 3 deletions
|
@ -316,9 +316,9 @@ function parseFileInfo(response) {
|
||||||
isDirectory: response.isDirectory,
|
isDirectory: response.isDirectory,
|
||||||
isSymlink: response.isSymlink,
|
isSymlink: response.isSymlink,
|
||||||
size: response.size,
|
size: response.size,
|
||||||
mtime: response.mtimeSet !== null ? new Date(response.mtime) : null,
|
mtime: response.mtimeSet === true ? new Date(response.mtime) : null,
|
||||||
atime: response.atimeSet !== null ? new Date(response.atime) : null,
|
atime: response.atimeSet === true ? new Date(response.atime) : null,
|
||||||
birthtime: response.birthtimeSet !== null
|
birthtime: response.birthtimeSet === true
|
||||||
? new Date(response.birthtime)
|
? new Date(response.birthtime)
|
||||||
: null,
|
: null,
|
||||||
dev: response.dev,
|
dev: response.dev,
|
||||||
|
|
Loading…
Add table
Reference in a new issue