Remove unnecessary null check.

This commit is contained in:
akwizgran
2019-04-26 17:58:08 +01:00
parent 0c99ef0e5b
commit ebae1037be

View File

@@ -103,7 +103,6 @@ class IdentityManagerImpl implements IdentityManager, OpenDatabaseHook {
db.addAccount(txn, cached);
LOG.info("Account stored");
} else if (shouldStoreKeys) {
requireNonNull(cached);
byte[] publicKey = requireNonNull(cached.getHandshakePublicKey());
byte[] privateKey = requireNonNull(cached.getHandshakePrivateKey());
db.setHandshakeKeyPair(txn, cached.getId(), publicKey, privateKey);