Sonar check fix: Use Index Of Char.