| 209 | // 2022-07-19T01:20:12.172Z. Note how the 6th month (July) becomes |
| 210 | // '07'. All numbers become 2 character zero-padding strings individually. |
| 211 | function utcTimestamp() { |
| 212 | const d = new Date() |
| 213 | |
| 214 | return ( |
| 215 | [ |
| 216 | `${d.getUTCFullYear()}`, |
| 217 | d.getUTCMonth() + 1, |
| 218 | d.getUTCDate(), |
| 219 | d.getUTCHours(), |
| 220 | d.getUTCMinutes(), |
| 221 | d.getUTCSeconds(), |
| 222 | ] |
| 223 | // If it's a number make it a zero-padding 2 character string |
| 224 | .map((x) => (typeof x === 'number' ? ('0' + x).slice(-2) : x)) |
| 225 | .join('') |
| 226 | ) |
| 227 | } |
| 228 | |
| 229 | // Consider moving this to lib |
| 230 | async function indexVersion( |