Reordered if-clauses