Fix "Maximum call stack size exceeded" warnings when processing lots of

items