mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-23 12:52:07 +01:00
EncryptionOptions: Consistent exceptions
This commit is contained in:
parent
512825aad4
commit
e297dfd3c1
1 changed files with 1 additions and 1 deletions
|
@ -146,7 +146,7 @@ public class EncryptionOptions {
|
|||
List<PGPPublicKey> encryptionSubkeys = encryptionKeySelectionStrategy
|
||||
.selectEncryptionSubkeys(info.getEncryptionSubkeys(userId, purpose));
|
||||
if (encryptionSubkeys.isEmpty()) {
|
||||
throw new AssertionError("Key has no suitable encryption subkeys.");
|
||||
throw new IllegalArgumentException("Key has no suitable encryption subkeys.");
|
||||
}
|
||||
|
||||
for (PGPPublicKey encryptionSubkey : encryptionSubkeys) {
|
||||
|
|
Loading…
Reference in a new issue