diff options
author | Determinant <[email protected]> | 2024-09-09 00:38:02 -0700 |
---|---|---|
committer | Determinant <[email protected]> | 2024-09-09 00:38:02 -0700 |
commit | 385077c96dbf91b51c9d7b465e0654c789784041 (patch) | |
tree | 7fb668719d7d61a31d34588421c7148622ec3676 | |
parent | 9b6c569fe8febf4df08a6402a07f1e43f5f453b1 (diff) |
...
-rwxr-xr-x | app.mjs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -29,7 +29,7 @@ const getChartSupplementDiretory = async () => { if (files[region]) { files[region].push({ url, date }); if (moment() >= date) { - files[region].current = { url, date: m[2] }; + files[region].current = { url, date: date.format('YYYY-MM-DD') }; } } } @@ -66,7 +66,7 @@ const getTerminalProcedurePublication = async () => { files[region].push({ url, date }); files[region].current = { url, - date: date.format("YYYYMMDD"), + date: date.format("YYYY-MM-DD"), }; } } @@ -87,7 +87,7 @@ const res = [ for (let r of res) { for (let region of Object.keys(r.files)) { const cur = r.files[region].current; - const file = `${r.prefix}-${region}-${cur.date}.pdf`; + const file = `${r.prefix}-${region.toLowerCase()}-${cur.date}.pdf`; const fileExists = (path) => fs.stat(path).then( () => true, |