fixed comparison bug in previous commit