Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf: Only do memory allocation when zero coin is found (backport #10…
…339) (#10361) * perf: Only do memory allocation when zero coin is found (#10339) ## Description Closes: #10333 Added a loop that checks for zero coins before making any memory allocations. If no zero coins are found, just return the `coins` slice as is. If a zero coin is found, then allocate the new array, stop looking for the first zero, and restart the loop to "remove" the 0's.
- Loading branch information