From 1267684614aa8fbab868f3aa1e688a07b760c9fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Richard=20K=C3=B6rber?= Date: Sun, 13 Dec 2015 14:42:02 +0100 Subject: [PATCH] Fail if no keypair is set --- acme4j-client/src/main/java/org/shredzone/acme4j/Account.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/acme4j-client/src/main/java/org/shredzone/acme4j/Account.java b/acme4j-client/src/main/java/org/shredzone/acme4j/Account.java index 1c97b275..64324d77 100644 --- a/acme4j-client/src/main/java/org/shredzone/acme4j/Account.java +++ b/acme4j-client/src/main/java/org/shredzone/acme4j/Account.java @@ -33,6 +33,10 @@ public class Account { * {@link KeyPair} that identifies the account. */ public Account(KeyPair keyPair) { + if (keyPair == null) { + throw new NullPointerException("keypair must be set"); + } + this.keyPair = keyPair; }