Fixed PMD warnings