mirror of
				https://github.com/oxen-io/session-android.git
				synced 2025-11-04 11:11:40 +00:00 
			
		
		
		
	minor refactoring
This commit is contained in:
		@@ -275,11 +275,8 @@ fun MessageSender.sendLatestEncryptionKeyPair(publicKey: String, groupPublicKey:
 | 
				
			|||||||
        return
 | 
					        return
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    // Get the latest encryption key pair
 | 
					    // Get the latest encryption key pair
 | 
				
			||||||
    val encryptionKeyPair = if (pendingKeyPair[groupPublicKey] != null && pendingKeyPair[groupPublicKey]!!.isPresent) {
 | 
					    val encryptionKeyPair = pendingKeyPair[groupPublicKey]?.orNull()
 | 
				
			||||||
        pendingKeyPair[groupPublicKey]!!.get()
 | 
					            ?: storage.getLatestClosedGroupEncryptionKeyPair(groupPublicKey) ?: return
 | 
				
			||||||
    } else {
 | 
					 | 
				
			||||||
        storage.getLatestClosedGroupEncryptionKeyPair(groupPublicKey)
 | 
					 | 
				
			||||||
    } ?: return
 | 
					 | 
				
			||||||
    // Send it
 | 
					    // Send it
 | 
				
			||||||
    val proto = SignalServiceProtos.KeyPair.newBuilder()
 | 
					    val proto = SignalServiceProtos.KeyPair.newBuilder()
 | 
				
			||||||
    proto.publicKey = ByteString.copyFrom(encryptionKeyPair.publicKey.serialize())
 | 
					    proto.publicKey = ByteString.copyFrom(encryptionKeyPair.publicKey.serialize())
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user