Clean insert logic - also boosts performance a tad.