(fn: (host: QueueHost) => T)
| 10 | } |
| 11 | |
| 12 | #withHost<T>(fn: (host: QueueHost) => T): T { |
| 13 | const host = this.#host; |
| 14 | if (!host) { |
| 15 | throw new Error('Queue host not available'); |
| 16 | } |
| 17 | return fn(host); |
| 18 | } |
| 19 | |
| 20 | getQueue() { |
| 21 | return this.#withHost((h) => h.getQueue()); |
no test coverage detected