title: Actionhero actions returning immediately
body: <p>I'm trying to understand a core concept of ActionHero async/await and hitting lots of walls. Essentially, in an action, why does this return immediately, rather than 500ms later?</p>
  
  <pre><code>async run (data) {
    setTimeout(() =&gt; data.response.outcome = 'success',500)
  }
  </code></pre>
  
  <p>Clarifying edit: this question was more about async execution flow and promise fulfillment than about the literal use of setTimeout(). Its not really specific to ActionHero but that's the pattern AH uses and was my first exposure to the concepts. The answer provided clarifies that some functions have to be wrapped in a promise so they can be await-ed and that there are multiple ways to do that.</p>