Resolved more sonar issues