Async Await
async function asyncFunction(x) { let result = await queryThisToDB("SELECT * FROM my_table"); return result; } queryThisToDB(query) { // some logic }