fixed formatting and sorting