title: calling a async function inside then
body: <p>I have a piece of code that looks like this:</p>
  
  <pre><code>func().then(function (result){
     var a = func1(result);
     func2(a).then(function(result1){
      ////
     }
  }
  </code></pre>
  
  <p>As you can see <code>func</code> returns a promise, and in then part we call another <code>func1</code> which also returns a promise. Is it possible to chain the promise returned from <code>func2</code> with the promise of then, and somehow get ride of the nested functions in the second then.</p>