forked from TrueCloudLab/lego
Loading an account from file should fail if a integral part is nil.
Fixes #191
This commit is contained in:
parent
96a24777ff
commit
d93c71b61f
1 changed files with 8 additions and 0 deletions
|
@ -64,6 +64,14 @@ func NewAccount(email string, conf *Configuration) *Account {
|
|||
acc.key = privKey
|
||||
acc.conf = conf
|
||||
|
||||
if acc.Registration == nil {
|
||||
logger().Fatalf("Could not load account for %s. Registration is nil.", email)
|
||||
}
|
||||
|
||||
if acc.conf == nil {
|
||||
logger().Fatalf("Could not load account for %s. Configuration is nil.", email)
|
||||
}
|
||||
|
||||
return &acc
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue