From eff265962c081edb751d5d2ed99dc443cb97f3fb Mon Sep 17 00:00:00 2001 From: Krishnajinka Date: Wed, 18 Jul 2018 19:49:30 +0900 Subject: FIX SONAR ISSUE NESTED TRY BLOCKS refactor the code for nested try blocks and rework based on comments and fix nested loops complexity Issue-ID: POLICY-976 Change-Id: Ied02b7838b5e4839a4906f79ff37c4fd6afeccfe Signed-off-by: Krishnajinka --- .../src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ONAP-XACML/src/main/java/org/onap') diff --git a/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java b/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java index 168bc54f5..ecbd3faa8 100644 --- a/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java +++ b/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java @@ -147,7 +147,7 @@ public class XACMLPolicyWriter { return new ByteArrayInputStream(byteArrayOutputStream.toByteArray()); } catch (JAXBException e) { PolicyLogger.error(MessageCodes.ERROR_DATA_ISSUE, e, "XACMLPolicyWriter", "writePolicyFile failed"); - return null; + throw new IllegalArgumentException("XACMLPolicyWriter writePolicyFile failed", e); } } /** -- cgit 1.2.3-korg