(previous: string)
| 252 | } |
| 253 | |
| 254 | function timestampAfter(previous: string): string { |
| 255 | const now = new Date(); |
| 256 | const previousMs = Date.parse(previous); |
| 257 | if (Number.isFinite(previousMs) && now.getTime() <= previousMs) { |
| 258 | return new Date(previousMs + 1).toISOString(); |
| 259 | } |
| 260 | return now.toISOString(); |
| 261 | } |
| 262 | |
| 263 | function isErrno(error: unknown, code: string): boolean { |
| 264 | return isRecord(error) && error['code'] === code; |
no outgoing calls
no test coverage detected