From b0ef436ec7cf19159cd1a90c620c0561adfa6463 Mon Sep 17 00:00:00 2001 From: Christoph Sturm Date: Tue, 13 Aug 2019 15:52:49 +0200 Subject: [PATCH] fix missing annotation --- .../java/bisq/core/notifications/MobileMessageEncryption.java | 2 ++ desktop/src/test/java/bisq/desktop/GuiceSetupTest.java | 2 ++ 2 files changed, 4 insertions(+) diff --git a/core/src/main/java/bisq/core/notifications/MobileMessageEncryption.java b/core/src/main/java/bisq/core/notifications/MobileMessageEncryption.java index 0b6195872b7..37ddfe88d41 100644 --- a/core/src/main/java/bisq/core/notifications/MobileMessageEncryption.java +++ b/core/src/main/java/bisq/core/notifications/MobileMessageEncryption.java @@ -18,6 +18,7 @@ package bisq.core.notifications; import javax.inject.Inject; +import javax.inject.Singleton; import com.google.common.base.Charsets; @@ -33,6 +34,7 @@ import lombok.extern.slf4j.Slf4j; @Slf4j +@Singleton public class MobileMessageEncryption { private SecretKeySpec keySpec; private Cipher cipher; diff --git a/desktop/src/test/java/bisq/desktop/GuiceSetupTest.java b/desktop/src/test/java/bisq/desktop/GuiceSetupTest.java index daa0fc76bc2..68feb00202f 100644 --- a/desktop/src/test/java/bisq/desktop/GuiceSetupTest.java +++ b/desktop/src/test/java/bisq/desktop/GuiceSetupTest.java @@ -24,6 +24,7 @@ import bisq.core.locale.CurrencyUtil; import bisq.core.locale.Res; import bisq.core.network.p2p.seed.DefaultSeedNodeRepository; +import bisq.core.notifications.MobileMessageEncryption; import bisq.core.notifications.MobileModel; import bisq.core.notifications.MobileNotificationService; import bisq.core.notifications.MobileNotificationValidator; @@ -118,6 +119,7 @@ public void testGuiceSetup() { assertSingleton(PersistenceProtoResolver.class); assertSingleton(CorePersistenceProtoResolver.class); assertTrue(injector.getInstance(PersistenceProtoResolver.class) instanceof CorePersistenceProtoResolver); + assertSingleton(MobileMessageEncryption.class); assertSingleton(MobileNotificationService.class); assertSingleton(MobileNotificationValidator.class); assertSingleton(MobileModel.class);