Fixed updating weights when a weight is removed.