added additional sorting