(obj)
| 35 | } |
| 36 | |
| 37 | export function immutableRemoveUndefined(obj) { |
| 38 | if (!isObject(obj)) { |
| 39 | return obj; |
| 40 | } |
| 41 | const result = {}; |
| 42 | for (const [key, value] of Object.entries(obj)) { |
| 43 | if (value === undefined) continue; |
| 44 | |
| 45 | result[key] = value; |
| 46 | } |
| 47 | return result; |
| 48 | } |
| 49 | |
| 50 | export function immutableDeepMerge(target, source) { |
| 51 | if (!isObject(target) || !isObject(source)) { |
no test coverage detected