-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added api to pass errors from generators #7
Conversation
|
||
reject('foo'); | ||
|
||
var x = yield righto(function(done){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
var y
I have some reservations about the PR straight away, but I'm not sure if they are valid. calling I could solve this by |
I think it isn't worth the overhead. Also if you're using standard callbacks (without righto), you would already be accustomed to returning if the callback isn't at the last executable line of of the current function scope. |
}); | ||
}); | ||
|
||
reject('foo'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps change this to
if (x === 'x') {
return reject('foo');
}
So see the diff comment above, so the test now demonstrates that a Additional observation: Since |
I had coincided allowing to pass results there, but that does add ways to do the same task, which I'm not a huge fan of. It also wouldn't be a breaking change too add later, so, goat tracks and all that... |
'nuff said... merge! |
No description provided.