Fix quality flaws: "Collapsible "if" statements should be merged".
Fix quality flaws.