Fixed #4547 (Improve check: Duplicate conditions in 'if' and related 'else { if'.)

Local fix in CheckOther::checkDuplicateIf()