Zoey Prompts Refactor

Convert Callbacks to Async/Await

Shared by Zoey Prompts

# Refactor Request
Convert the callback-based code in [File Name, e.g. server/db.js] to async/await.

## Objectives
- Replace nested callbacks with async functions.
- Use try/catch for error handling with clear messages.
- Run independent calls in parallel with Promise.all.

## Constraints
- DO NOT change exported function names or what they return.
- Keep the same error behavior for callers.
Open in Zoey Prompts →

Write better AI coding prompts and get working code on the first try — free at zoeyprompts.com.