ConfusingTernaryCheck with restrictions