withDb<T> method
Runs action passing in a Db from the pool
Implementation
Future<T> withDb<T>({required Future<T> Function(Db db) action}) async {
final wrapper = await obtain();
try {
return action(wrapper.wrapped);
} finally {
await release(wrapper);
}
}