fixes
This commit is contained in:
@@ -181,7 +181,7 @@ export class ExponentialBackoff {
|
|||||||
// Validate the max attempts
|
// Validate the max attempts
|
||||||
assertIsFinite('maxAttempts', options.maxAttempts);
|
assertIsFinite('maxAttempts', options.maxAttempts);
|
||||||
assertIsInteger('maxAttempts', options.maxAttempts);
|
assertIsInteger('maxAttempts', options.maxAttempts);
|
||||||
assertIsHigherThan('maxAttempts', options.maxAttempts, 0);
|
assertIsHigherThan('maxAttempts', options.maxAttempts, -1);
|
||||||
|
|
||||||
// Validate the base delay
|
// Validate the base delay
|
||||||
assertIsFinite('baseDelay', options.baseDelay);
|
assertIsFinite('baseDelay', options.baseDelay);
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import type { SSESessionOptions, SSESessionEventMap, SSEvent } from './types.ts';
|
import type { SSESessionOptions, SSESessionEventMap, SSEvent } from './types.ts';
|
||||||
|
|
||||||
import { EventEmitter } from 'eventemitter3';
|
import { EventEmitter } from '../event-emitter.ts';
|
||||||
|
|
||||||
import { HTTPError, ResponseBodyNullError } from '../errors.ts';
|
import { HTTPError, ResponseBodyNullError } from '../errors.ts';
|
||||||
import { tryAsync } from '../misc.ts';
|
import { tryAsync } from '../misc.ts';
|
||||||
|
|||||||
Reference in New Issue
Block a user