Skip to content

Conversation

@aearly
Copy link
Collaborator

@aearly aearly commented Mar 12, 2016

This splits out the old "control flow" behavior from retry. It wraps a task, rather than immediate running it.

@megawac would love your code review, as well as perhaps an idea for a better name?

lib/retryable.js Outdated
return rest(function (args) {
var callback = args.pop();
retry(opts, function (cb) {
task(...args.concat([cb]));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove splat?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch.

@aearly
Copy link
Collaborator Author

aearly commented Mar 12, 2016

What do you think about the retryable name?

aearly added a commit that referenced this pull request Mar 18, 2016
added retryable wrapper for async tasks
@aearly aearly merged commit bdf4a96 into master Mar 18, 2016
@aearly aearly added this to the 2.0 milestone Mar 24, 2016
@megawac megawac deleted the retryable branch April 12, 2016 22:56
@megawac megawac restored the retryable branch April 12, 2016 22:56
@megawac megawac deleted the retryable branch April 12, 2016 22:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants