adding sort functionality for both TLC and Replies, still needs more testing