title: Q.all array of request promises, not sure how to get the results
body: <p>Probably an obvious answer to this but I'm not sure what way to take.
  request is a node module: <a href="https://github.com/request/request" rel="nofollow">https://github.com/request/request</a>
  I fill an array of getHistory requests (with different parameters). p = [p1,p2...].</p>
  
  <pre><code>this.app.all('/api/heatmap', function(req,res) {
     // fill p here _.each(blabla, p.push(gethistory(someparams...)
     var result = [];
     function getHistory(params) {
          var options = { ...};
          var callback = function(error, response, body) {
              if(error) { //wtv 
              } else {
                // what to do with the body here ? return body ? result.push(body) ?
              }
          }
  
          request(options, callback);
      }
  
      Q.all(p).then(function() {
      });
  }
  </code></pre>
  
  <p>So the problem here is that I when all of the request to be done , put everything in an array/object then send the whole thing to the client. How to have getHistory returning the fetched value (after the request is done ).</p>
  
  <p>Hope it's clear.</p>