(
operation: Callable[[], T | Awaitable[T]] | T | Awaitable[T],
)
| 14 | |
| 15 | |
| 16 | async def run_maybe_async( |
| 17 | operation: Callable[[], T | Awaitable[T]] | T | Awaitable[T], |
| 18 | ) -> T: |
| 19 | result: Any = operation() if callable(operation) else operation |
| 20 | return await resolve_maybe_awaitable(result) |
no test coverage detected