remove extra code for sorting