Found this allocation when looking for a memory leak using chrome developer tools (allocation sampling). Other places in the file correctly uses obj.filter
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Remove redundant spread
processKeysInObj
.Description
Avoid unnecessary memory allocation.
Testing
Filter is already returning a shallow copy of the array see:
Additional context
Found this allocation when looking for a memory leak using chrome developer tools (allocation sampling). Other places in the file correctly uses
obj.filter
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.