fixed reorder to mutate vector