--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+unsubscribe@googlegroups.com.
To post to this group, send email to nod...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/88274485-8c08-4e79-bb5f-829655b97c7e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
To post to this group, send email to nod...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/0fab98fb-38e4-4aeb-bf65-d899fd08d0d9%40googlegroups.com.
Here is my code. Its a simple one
for(var a=0; a<dResponse.length;a++ ){
var dId = dResponse[a].dId;
console.log('dId-->' +dResponse);
var dUrl = url?id=' + dId;
console.log('Url:'+dUrl);
}
Every time it returns the same url.
const request = require('request');
function callRemoteApi(url) { return new Promise((resolve, reject) => { console.log('Fetching', url); request(url, (err, res) => { if (err) { return reject(err); } console.log('Got', url); const result = JSON.parse(res.body).url; resolve(result); }); });}async function runTest() { const urls = [ ]; console.log('Urls ready.'); let promises = []; for (let url of urls) { promises.push(callRemoteApi(url)); }; console.log('Promises ready.'); await Promise.all(promises.map(async promise => console.log('Result of promise:' + await promise))) .then(() => console.log('All done.'));}
runTest();To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+unsubscribe@googlegroups.com.
To post to this group, send email to nod...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/0fab98fb-38e4-4aeb-bf65-d899fd08d0d9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+unsubscribe@googlegroups.com.
To post to this group, send email to nod...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/07723C4D-E2BD-48D1-826C-7FFCA51C3692%40gmail.com.
--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/572a0df8-4ecf-43e0-9ee4-fe3757bc8cd1%40googlegroups.com.