Reduce Sonar issues