aboutsummaryrefslogtreecommitdiffstats
path: root/cloudify-client
diff options
context:
space:
mode:
Diffstat (limited to 'cloudify-client')
-rw-r--r--cloudify-client/src/main/java/org/onap/so/cloudify/base/client/CloudifyClientTokenProvider.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/cloudify-client/src/main/java/org/onap/so/cloudify/base/client/CloudifyClientTokenProvider.java b/cloudify-client/src/main/java/org/onap/so/cloudify/base/client/CloudifyClientTokenProvider.java
index 2478557afc..c4dcc89d0b 100644
--- a/cloudify-client/src/main/java/org/onap/so/cloudify/base/client/CloudifyClientTokenProvider.java
+++ b/cloudify-client/src/main/java/org/onap/so/cloudify/base/client/CloudifyClientTokenProvider.java
@@ -59,7 +59,9 @@ public class CloudifyClientTokenProvider implements CloudifyTokenProvider {
tokenRequest.setBasicAuthentication(user, password);
Token newToken = tokenRequest.execute();
- token = newToken.getValue();
+ if (newToken != null) {
+ token = newToken.getValue();
+ }
if (expiration == null) {
expiration = new Date();