( nowMillis: number, value: string | undefined )
| 1914 | |
| 1915 | // The one millisecond floor keeps a past date or `0` from retrying immediately. |
| 1916 | const parseRetryAfter = ( |
| 1917 | nowMillis: number, |
| 1918 | value: string | undefined |
| 1919 | ): Duration.Duration | undefined => { |
| 1920 | const delay = retryAfterDelay(nowMillis, value) |
| 1921 | return delay === undefined ? undefined : Duration.max(delay, Duration.millis(1)) |
| 1922 | } |
| 1923 | |
| 1924 | const parseResetAfter = (value: string | undefined): Duration.Duration | undefined => { |
| 1925 | const numeric = parseNumberHeader(value) |
no test coverage detected