Fix if clauses two places.

Two if statement checks need to be negated.