fix of some sonar violations