diff options
Diffstat (limited to 'appc-common')
-rw-r--r-- | appc-common/src/main/java/org/onap/appc/encryption/EncryptionTool.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/appc-common/src/main/java/org/onap/appc/encryption/EncryptionTool.java b/appc-common/src/main/java/org/onap/appc/encryption/EncryptionTool.java index 480b15e06..37205fc75 100644 --- a/appc-common/src/main/java/org/onap/appc/encryption/EncryptionTool.java +++ b/appc-common/src/main/java/org/onap/appc/encryption/EncryptionTool.java @@ -108,13 +108,9 @@ public class EncryptionTool { * * @return The encryption tool to be used */ - public static final EncryptionTool getInstance() { + public static final synchronized EncryptionTool getInstance() { if (instance == null) { - synchronized (lock) { - if (instance == null) { - instance = new EncryptionTool(); - } - } + instance = new EncryptionTool(); } return instance; } |