@fix compare funtion