Code cleanup
Allow null weights to discard any weighting