node-googlemaps icon indicating copy to clipboard operation
node-googlemaps copied to clipboard

Successive request via gmAPI not working

Open aj07mm opened this issue 10 years ago • 1 comments

Hi! i have this function:

gmAPI.directions(params, function(err, res){
      var duration  = res.routes[0].legs[0].duration.text;
      console.log(duration);
});

inside a two for loop, and it doesn't pass the first call, it stays there. I tried settimeout with 1000 and 3000 but no go, any of you guys know the prob?

aj07mm avatar Jan 15 '16 17:01 aj07mm

You might need to publish a bit more of your code to receive proper help.

fabriziomoscon avatar Jan 21 '16 15:01 fabriziomoscon