Sorting of the posts and comments