[REFACTOR] refs #35774 @ 0.1 Refactored some ifs and comments