mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-10-29 17:52:32 +00:00
Error out if cluster information is nil when Vault is unsealed
This commit is contained in:
@@ -123,10 +123,11 @@ func getSysHealth(core *vault.Core, r *http.Request) (int, *HealthResponse, erro
|
||||
if err != nil {
|
||||
return http.StatusInternalServerError, nil, err
|
||||
}
|
||||
if cluster != nil {
|
||||
clusterName = cluster.Name
|
||||
clusterID = cluster.ID
|
||||
if cluster == nil {
|
||||
return http.StatusInternalServerError, nil, nil
|
||||
}
|
||||
clusterName = cluster.Name
|
||||
clusterID = cluster.ID
|
||||
}
|
||||
|
||||
// Format the body
|
||||
|
||||
Reference in New Issue
Block a user