NXP-12847: fix Sonar violations