Skip to content

Commit 955a226

Browse files
committed
fix(typescript): return invalid date for non-existent file stat
1 parent a8a7417 commit 955a226

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/typescript/lib/protocol/createSys.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ export function createSys(
180180
file.requestedStat = true;
181181
handleStat(fileName, file);
182182
}
183-
return file.stat ? new Date(file.stat.mtime) : new Date(0);
183+
return file.stat ? new Date(file.stat.mtime) : new Date(-1);
184184
}
185185

186186
function fileExists(fileName: string): boolean {

0 commit comments

Comments
 (0)