-
Notifications
You must be signed in to change notification settings - Fork 13
chore: convert to async await syntax #28
Conversation
vasco-santos
left a comment
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.
It looks good to me! Just asked minor things to get this to the finish line
src/utils/p-try-each.js
Outdated
| @@ -0,0 +1,25 @@ | |||
| 'use strict' | |||
|
|
|||
| const pTryEeach = async (iterable) => { | |||
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.
Can you create a module for this?
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.
Yes, I can and I will. Can we merge this as it is and then update it later to use the module that I'll create?
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.
you have a typo in the fn name pTryEeachshould be pTryEach
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.
Oops 🤦♂️
src/utils/p-try-each.js
Outdated
| @@ -0,0 +1,25 @@ | |||
| 'use strict' | |||
|
|
|||
| const pTryEeach = async (iterable) => { | |||
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.
you have a typo in the fn name pTryEeachshould be pTryEach
61e7445 to
e4e672c
Compare
BREAKING CHANGE: All places in the API that used callbacks are now replaced with async/await Co-authored-by: PedroMiguelSS <[email protected]>
This PR converts this module's both exported
getResponseandresolverfunctions to async/await syntax.It also adds a util file called
p-try-eachthat mimics the sameasync/tryEachmethod.Closes #27.