title: make http call from within another http call in angular
body: <p>I call an http service, loop through the results and each item acts as the key for another http-call. </p>
  
  <p>What's the best way to do that?</p>
  
  <p>I guess calling $http from within another $http call does not work as the outer $http-loop may just exit before the inner $http calls
  have finished?</p>
  
  <p>// pseudo code:</p>
  
  <pre><code>$http.get(url).then((response) -&gt;
    foreach response.data as item
          $http.get(item.url).then((response) -&gt;
            foreach response.data as item
          )
    return result
  )
  </code></pre>
  
  <p>Doesn't really work, right?</p>