( label: string, run: () => Promise<A>, )
| 79 | }; |
| 80 | |
| 81 | export const fumaEffect = <A>( |
| 82 | label: string, |
| 83 | run: () => Promise<A>, |
| 84 | ): Effect.Effect<A, StorageFailure> => |
| 85 | Effect.tryPromise({ |
| 86 | try: run, |
| 87 | catch: (cause) => fumaFailureFromCause(label, cause), |
| 88 | }); |
| 89 | |
| 90 | export const activeFumaDbRef = Context.Reference<FumaDb | null>("executor/ActiveFumaDb", { |
| 91 | defaultValue: () => null, |
no test coverage detected