sorting of users on frontend side