Correct reversed if logig