Await all queued work. Call before returning the response. Loops until the
queue stays empty: work already running can queue more (a background job
that fails queues its error's activity-log write), and a single pass would
discard those late arrivals unawaited.
Return Type
Promise<void>
Usage
import { flushPendingWork } from "docs/utilities.ts";