antongolub/push-it-to-the-limit

View on GitHub
src/main/ts/wrappers/ratelimit.ts

Summary

Maintainability
A
1 hr
Test Coverage
A
100%

Function ratelimit has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export const ratelimit: IExposedWrapper = adapter((fn: ITarget, opts: IWrapperOpts): IControlled => {
  let timeout: TimeoutID | undefined
  const { delay, limit, context, rejectOnCancel, limiter } = opts
  const _limiter = limiter || new Limiter(normalizeDelay(limit || delay))
  const calls: ICallStack = []
Severity: Minor
Found in src/main/ts/wrappers/ratelimit.ts - About 1 hr to fix

    There are no issues that match your filters.

    Category
    Status