Modifications on CompareRanks class