(value: T | (() => T))
| 52 | * Unwrap a value which might be behind a closure (for forward declaration reasons). |
| 53 | */ |
| 54 | export function maybeUnwrapFn<T>(value: T | (() => T)): T { |
| 55 | if (value instanceof Function) { |
| 56 | return value(); |
| 57 | } else { |
| 58 | return value; |
| 59 | } |
| 60 | } |
no test coverage detected
searching dependent graphs…