title: Is not awaiting certain promises wrong?
body: <p>Using express I have one REST route where I fetch some data. Within this request I also add an entry into an event table (for app insights purposes) in the database. I do not really care to wait for that event to be saved before returning the actual data to the requester, since saving the event is not that important for the end user.</p>
  <p>Something like this pseudo code:</p>
  <pre><code>const data = await getResponseDataFromDatabase();
  
  insertInsightsEventIntoDatabase(); // returns a promise which I don't want to wait for
  
  return data;
  </code></pre>
  <p>Since there was a bug in the insertInsightsEventIntoDatabase I got this error in the logs:</p>
  <pre><code>This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
  Error: Cannot set headers after they are sent to the client
  </code></pre>
  <p>If I await the insertInsightsEventIntoDatabase() I would get a much better error log in the console that shows an error from the ORM I am using.</p>
  <p>My question is, it it wrong to not await the method? I like the idea of not awaiting it just to have it &quot;run in the background&quot; and not blocking the time it takes to send the response on the client request. The drawback is that the real error seems to be swallowed and I would very much like to have the original error in the logs.</p>
  <p>Am I doing this wrong?</p>