MCPcopy
hub / github.com/sindresorhus/p-queue / onRateLimit

Method onRateLimit

source/index.ts:707–713  ·  view source on GitHub ↗

@returns A promise that settles when the queue becomes rate-limited due to intervalCap.

()

Source from the content-addressed store, hash-verified

705 @returns A promise that settles when the queue becomes rate-limited due to intervalCap.
706 */
707 async onRateLimit(): Promise<void> {
708 if (this.isRateLimited) {
709 return;
710 }
711
712 await this.#onEvent('rateLimit');
713 }
714
715 /**
716 @returns A promise that settles when the queue is no longer rate-limited.

Callers 3

advanced.tsFile · 0.80
rate-limit.tsFile · 0.80
strict.tsFile · 0.80

Calls 1

#onEventMethod · 0.95

Tested by

no test coverage detected