Andrew Nicols f57af194fb
MDL-78316 core: Update async promises
Writing a Promise as:
```
const promise = new Promise(async (resolve, reject) => {
  return await 'foo';
});
```

Is equivalent to an IIFE:
```
const promise = (async () => {
  return await 'foo';
})();
```

A recent change introduced by MDL-74301 picks this up.

This commit addresses this flagged issue.
2023-07-07 16:23:26 +08:00
..
2023-07-07 16:23:26 +08:00