Verify assumption

This commit is contained in:
Manav Rathi 2024-04-28 20:38:14 +05:30
parent 13f0ff3af5
commit 24b64f9522
No known key found for this signature in database

View file

@ -110,7 +110,11 @@ const handleReadZip = async (zipPath: string, zipEntryPath: string) => {
// browser doesn't tinker with it thinking of it as text.
"Content-Type": "application/octet-stream",
"Content-Length": `${entry.size}`,
// !!TODO(MR): Is this ms
// While it is documented that entry.time is the modification
// time, the units are not mentioned. By seeing the source code,
// we can verify that it is indeed epoch milliseconds. See
// `parseZipTime` in the node-stream-zip source,
// https://github.com/antelle/node-stream-zip/blob/master/node_stream_zip.js
"X-Last-Modified-Ms": `${entry.time}`,
},
});