This does not await:
array.forEach(async x => await save(x));
✅ Fix
for (const x of array) {
await save(x);
}
Daily micro-tips for C#, SQL, performance, and scalable backend engineering.
This does not await:
array.forEach(async x => await save(x));
✅ Fix
for (const x of array) {
await save(x);
}