Browse Source

Fix KeyMaterial nil bug (#5849)

pull/5855/head
qinguoyi 5 months ago
committed by GitHub
parent
commit
bf2366ba3a
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 3
      weed/command/filer.go

3
weed/command/filer.go

@ -240,6 +240,9 @@ func runFiler(cmd *Command, args []string) bool {
// GetCertificateWithUpdate Auto refreshing TSL certificate // GetCertificateWithUpdate Auto refreshing TSL certificate
func (fo *FilerOptions) GetCertificateWithUpdate(*tls.ClientHelloInfo) (*tls.Certificate, error) { func (fo *FilerOptions) GetCertificateWithUpdate(*tls.ClientHelloInfo) (*tls.Certificate, error) {
certs, err := fo.certProvider.KeyMaterial(context.Background()) certs, err := fo.certProvider.KeyMaterial(context.Background())
if certs == nil {
return nil, err
}
return &certs.Certs[0], err return &certs.Certs[0], err
} }

Loading…
Cancel
Save