Fixed sonar violations