(config, updates)
| 127 | } |
| 128 | |
| 129 | const updateConfig = (config, updates) => { |
| 130 | if (Array.isArray(updates)) { |
| 131 | config.value = updates.map(update => { |
| 132 | return toConfig(null, update); |
| 133 | })?.filter(item => item !== null); |
| 134 | } else if (typeof updates === 'object') { |
| 135 | updateObject(updates, config); |
| 136 | } else { |
| 137 | config.value = updates; |
| 138 | } |
| 139 | }; |
| 140 | |
| 141 | const updateObject = (updates, config) => { |
| 142 | Object.keys(updates).forEach(k => { |
no test coverage detected