cleanup: removed unnecessary if clauses