diff --git a/lib/src/main/java/org/asamk/signal/manager/helper/PreKeyHelper.java b/lib/src/main/java/org/asamk/signal/manager/helper/PreKeyHelper.java index ea5ccdab..7a959dd2 100644 --- a/lib/src/main/java/org/asamk/signal/manager/helper/PreKeyHelper.java +++ b/lib/src/main/java/org/asamk/signal/manager/helper/PreKeyHelper.java @@ -45,11 +45,11 @@ public class PreKeyHelper { } public void refreshPreKeys(ServiceIdType serviceIdType) throws IOException { - final var oneTimePreKeys = generatePreKeys(serviceIdType); final var identityKeyPair = account.getIdentityKeyPair(serviceIdType); if (identityKeyPair == null) { return; } + final var oneTimePreKeys = generatePreKeys(serviceIdType); final var signedPreKeyRecord = generateSignedPreKey(serviceIdType, identityKeyPair); dependencies.getAccountManager()