(dest, src)
| 2 | * Shallow clone |
| 3 | */ |
| 4 | var clone = function (dest, src) { |
| 5 | // Clear destination |
| 6 | Object.keys(dest).forEach(function(key) { |
| 7 | dest[key] = void 0; |
| 8 | }); |
| 9 | // Copy source into destination |
| 10 | Object.keys(src).forEach(function(key) { |
| 11 | dest[key] = src[key]; |
| 12 | }); |
| 13 | }; |
| 14 | |
| 15 | /** |
| 16 | * Replace array contents with another array |
no outgoing calls
no test coverage detected
searching dependent graphs…