fix cr/contract sorting