fixed bug in basic pruning