FERM-43: fixing switched if statement