aboutsummaryrefslogtreecommitdiffstats
path: root/common-parameters/src
diff options
context:
space:
mode:
authorwaynedunican <wayne.dunican@est.tech>2024-08-12 21:18:12 +0100
committerwaynedunican <wayne.dunican@est.tech>2024-08-13 09:21:16 +0100
commit63d23a4aa0f3aeae9d6470b95dfa8f87b2d85aa8 (patch)
tree74aa5c14f66dc5760eb00ea8f18c278174cbc56e /common-parameters/src
parent34cad0af615db1ed4b85b8e4e1b77d0948289eed (diff)
Fix sonar issues in common
- SONAR Fix instanceOf issues - SONAR Remove public modifiers - SONAR Remove unused imports - SONAR Remove exceptions that can't be thrown from method body Issue-ID: POLICY-5106 Change-Id: I745d0101036d3421f02db22481514be0b79f5103 Signed-off-by: waynedunican <wayne.dunican@est.tech>
Diffstat (limited to 'common-parameters/src')
-rw-r--r--common-parameters/src/main/java/org/onap/policy/common/parameters/BeanValidator.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/common-parameters/src/main/java/org/onap/policy/common/parameters/BeanValidator.java b/common-parameters/src/main/java/org/onap/policy/common/parameters/BeanValidator.java
index 4ed7e42c..c4244b27 100644
--- a/common-parameters/src/main/java/org/onap/policy/common/parameters/BeanValidator.java
+++ b/common-parameters/src/main/java/org/onap/policy/common/parameters/BeanValidator.java
@@ -3,6 +3,7 @@
* ONAP
* ================================================================================
* Copyright (C) 2020-2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2024 Nordix Foundation
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -307,7 +308,7 @@ public class BeanValidator {
return true;
}
- BeanValidationResult result2 = (value instanceof ParameterGroup ? ((ParameterGroup) value).validate()
+ BeanValidationResult result2 = (value instanceof ParameterGroup parameterGroup ? parameterGroup.validate()
: validateTop(fieldName, value));
if (result2.isClean()) {