()
| 981 | } |
| 982 | |
| 983 | const close = async () => { |
| 984 | closed = true |
| 985 | if (flushTimer) { |
| 986 | clearTimeout(flushTimer) |
| 987 | flushTimer = null |
| 988 | } |
| 989 | if (inflightWrites.size > 0) { |
| 990 | await Promise.allSettled(inflightWrites) |
| 991 | } |
| 992 | if (flushPromise) { |
| 993 | await flushPromise |
| 994 | } |
| 995 | await flushCore(false) |
| 996 | } |
| 997 | |
| 998 | const flushCore = async (scheduleOnFailure: boolean) => { |
| 999 | await writeQueue |
nothing calls this directly
no test coverage detected