Skip to content

Commit d6cff64

Browse files
committed
v2.0.1
1 parent 6b2f62a commit d6cff64

File tree

8 files changed

+13
-13
lines changed

8 files changed

+13
-13
lines changed

lib/Options.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
interface Options {
22
interval: number;
33
numAttempts: number;
4-
onAttempt?: (success: boolean) => void;
4+
onAttempt?: (iteration: number, success: boolean) => void;
55
}
66
export default Options;

lib/tryCall.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
import Options from './Options';
2-
declare const _default: <ReturnValueType>(func: () => ReturnValueType, {interval, numAttempts, onAttempt}: Options) => Promise<ReturnValueType>;
2+
declare const _default: <ReturnValueType>(func: (iteration: number) => ReturnValueType, {interval, numAttempts, onAttempt}: Options) => Promise<ReturnValueType>;
33
export default _default;

lib/tryCall.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/tryCall.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/tryUntil.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
import Options from './Options';
2-
declare const _default: <ReturnValueType>(func: () => ReturnValueType, validate: (val: ReturnValueType) => boolean, {numAttempts, interval, onAttempt}: Options) => Promise<ReturnValueType>;
2+
declare const _default: <ReturnValueType>(func: (iteration: number) => ReturnValueType, validate: (val: ReturnValueType) => boolean, {numAttempts, interval, onAttempt}: Options) => Promise<ReturnValueType>;
33
export default _default;

lib/tryUntil.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/tryUntil.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "tryfunc",
3-
"version": "2.0.0",
3+
"version": "2.0.1",
44
"description": "Calling throwing or failing functions",
55
"main": "lib/index.js",
66
"types": "lib/index.d.ts",
@@ -30,4 +30,4 @@
3030
"delay.js": ">=1.0.2",
3131
"tslib": ">=1.8.0"
3232
}
33-
}
33+
}

0 commit comments

Comments
 (0)