Corrected Sonar violations
Added more documentation