changing compare to to equals