(thing: readonly T[] | T | undefined | null)
| 4 | } |
| 5 | |
| 6 | export default function ensureArray<T>(thing: readonly T[] | T | undefined | null): readonly T[] { |
| 7 | if (isArray(thing)) return thing; |
| 8 | if (thing == null) return []; |
| 9 | return [thing]; |
| 10 | } |
no test coverage detected