added function to sort list automatically by name