aboutsummaryrefslogtreecommitdiffstats
path: root/models-errors/src/main
diff options
context:
space:
mode:
authoradheli.tavares <adheli.tavares@est.tech>2024-04-02 15:15:39 +0100
committeradheli.tavares <adheli.tavares@est.tech>2024-04-10 13:39:24 +0100
commit22afe401ca130eba6543f740039e8a3c13d11861 (patch)
treefd15c592ed84dd364757ccecd67438a9d2fe58b4 /models-errors/src/main
parent389c85c8e7213c10c17896f4c63d94e2b5e9d27a (diff)
Dependency management update
- including dependencies to pom.xml files only where they are used, avoiding extra dependencies being added in all packages. Issue-ID: POLICY-4945 Change-Id: I85b18befe3fe2877c754b1ac818d1b4994f9f7f9 Signed-off-by: adheli.tavares <adheli.tavares@est.tech>
Diffstat (limited to 'models-errors/src/main')
-rw-r--r--models-errors/src/main/java/org/onap/policy/models/errors/concepts/ErrorResponseUtils.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/models-errors/src/main/java/org/onap/policy/models/errors/concepts/ErrorResponseUtils.java b/models-errors/src/main/java/org/onap/policy/models/errors/concepts/ErrorResponseUtils.java
index 749651310..e571e4058 100644
--- a/models-errors/src/main/java/org/onap/policy/models/errors/concepts/ErrorResponseUtils.java
+++ b/models-errors/src/main/java/org/onap/policy/models/errors/concepts/ErrorResponseUtils.java
@@ -1,6 +1,6 @@
/*-
* ============LICENSE_START=======================================================
- * Copyright (C) 2019 Nordix Foundation.
+ * Copyright (C) 2019, 2024 Nordix Foundation.
* Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -42,14 +42,14 @@ public final class ErrorResponseUtils {
public static void getExceptionMessages(final ErrorResponse errorResponse, final Throwable throwable) {
errorResponse.setErrorMessage(throwable.getMessage());
- List<String> cascascadedErrorMessages = new ArrayList<>();
+ List<String> cascadedErrorMessages = new ArrayList<>();
for (var t = throwable; t != null; t = t.getCause()) {
- cascascadedErrorMessages.add(t.getMessage());
+ cascadedErrorMessages.add(t.getMessage());
}
- if (!cascascadedErrorMessages.isEmpty()) {
- errorResponse.setErrorDetails(cascascadedErrorMessages);
+ if (!cascadedErrorMessages.isEmpty()) {
+ errorResponse.setErrorDetails(cascadedErrorMessages);
}
}
}