removed extra comparing