sorted min issue