()
| 211 | * Initialize logger state and ensure console forwarding is installed. |
| 212 | */ |
| 213 | export async function initLogger(): Promise<void> { |
| 214 | if (initialized) return; |
| 215 | if (initPromise) return initPromise; |
| 216 | |
| 217 | initPromise = (async () => { |
| 218 | bootstrapLogger(); |
| 219 | initialized = true; |
| 220 | })(); |
| 221 | |
| 222 | return initPromise; |
| 223 | } |
| 224 | |
| 225 | /** |
| 226 | * Format data for logging |
no test coverage detected