not a logic change, this made it easier to understand and used a better equality operator.