Added a new type of sort and optimised the text.