Commit e7b52cd6 authored by Brad Davidson's avatar Brad Davidson Committed by Brad Davidson

Fix panic when secret-encrypt status is checked before runtime core is ready

parent f9403687
......@@ -79,6 +79,10 @@ func EncryptionStatus(control *config.Control) http.Handler {
func encryptionStatus(control *config.Control) (EncryptionState, error) {
state := EncryptionState{}
if control.Runtime.Core == nil {
return state, util.ErrCoreNotReady
}
providers, err := secretsencrypt.GetEncryptionProviders(control.Runtime)
if os.IsNotExist(err) {
return state, nil
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment