(cv: any | null)
| 47 | * |
| 48 | */ |
| 49 | export const handleNullArray = (cv: any | null): any | null => { |
| 50 | if (cv == null) { |
| 51 | return null; |
| 52 | } |
| 53 | if (Array.isArray(cv)) { |
| 54 | cv = cv.filter(v => v != null); |
| 55 | } |
| 56 | if (cv.length === 0) { |
| 57 | return null; |
| 58 | } |
| 59 | return cv; |
| 60 | }; |
| 61 | |
| 62 | /** |
| 63 | * Semantic null value to null |
no test coverage detected