endless pruning bug fix