You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Could the documentation of fs.utimes (It says the type is Integer, and NaN or Infinity, will be converted to Date.now()) be more clear about the arguments? It looks like I can pass new Date(), but Date.now() needs to be divided by 1000. According to MDN Date.prototype.valueOf() and Date.now() both return: "The number of milliseconds between 1 January 1970 00:00:00 UTC and the given date.". It would be nice if the documentation mentioned that if the value is an Integer, it will be handled as a timestamp with precision of seconds.
Could the documentation of
fs.utimes
(It says the type is Integer, and NaN or Infinity, will be converted toDate.now()
) be more clear about the arguments? It looks like I can passnew Date()
, butDate.now()
needs to be divided by 1000. According to MDNDate.prototype.valueOf()
andDate.now()
both return: "The number of milliseconds between 1 January 1970 00:00:00 UTC and the given date.". It would be nice if the documentation mentioned that if the value is an Integer, it will be handled as a timestamp with precision of seconds.Output
The text was updated successfully, but these errors were encountered: