fix: reset printToPDF queue after a rejection The module-scoped `pendingPromise` in `webContents.printToPDF` was chained with `.then(onFulfilled)` and never cleared. Once a call rejected (e.g. an out-of-range `pageRanges` like `"999"`), subsequent calls chained onto the rejected promise and short-circuited without ever invoking `_printToPDF` — so every following call re-surfaced the original error. Replace the shared variable with a per-`WebContents` `WeakMap` queue that swallows prior rejections before chaining and clears its entry once the tail drains. Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com> |
||
|---|---|---|
| .. | ||
| browser | ||
| common | ||
| isolated_renderer | ||
| node | ||
| preload_realm | ||
| renderer | ||
| sandboxed_renderer | ||
| utility | ||
| worker | ||