diff options
Diffstat (limited to 'lib/retry.js')
-rw-r--r-- | lib/retry.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/retry.js b/lib/retry.js index 5ef6971..55dce0a 100644 --- a/lib/retry.js +++ b/lib/retry.js @@ -122,7 +122,7 @@ export default function retry(opts, task, callback) { if (err && attempt++ < options.times && (typeof options.errorFilter != 'function' || options.errorFilter(err))) { - setTimeout(retryAttempt, options.intervalFunc(attempt)); + setTimeout(retryAttempt, options.intervalFunc(attempt - 1)); } else { callback(err, ...args); } |