fix inverted logic
remove redundant condition