1
0
Fork 0
mirror of https://github.com/pgpainless/pgpainless.git synced 2024-11-18 02:12:06 +01:00

Simplify KeyReader

This commit is contained in:
Paul Schaub 2023-05-16 16:48:21 +02:00
parent 5c11b8af08
commit 7d049d0ac4
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311

View file

@ -35,7 +35,7 @@ class KeyReader {
throw e;
}
if (requireContent && (keys == null || keys.size() == 0)) {
if (requireContent && keys.size() == 0) {
throw new SOPGPException.BadData(new PGPException("No key data found."));
}
@ -53,7 +53,7 @@ class KeyReader {
}
throw e;
}
if (requireContent && (certs == null || certs.size() == 0)) {
if (requireContent && certs.size() == 0) {
throw new SOPGPException.BadData(new PGPException("No cert data found."));
}
return certs;