Fix expecting wrong status code for acme api calls

This commit is contained in:
Melon 2023-07-11 14:23:28 +01:00
parent 6057f82198
commit 78734a1e01
Signed by: melon
GPG Key ID: 6C9D970C50D26A25

View File

@ -54,7 +54,7 @@ func (h *HttpAcmeProvider) Present(domain, token, keyAuth string) error {
if err != nil { if err != nil {
return err return err
} }
if trip.StatusCode != http.StatusOK { if trip.StatusCode != http.StatusAccepted {
return fmt.Errorf("Trip response status code was not 200") return fmt.Errorf("Trip response status code was not 200")
} }
return nil return nil
@ -68,7 +68,7 @@ func (h *HttpAcmeProvider) CleanUp(domain, token, keyAuth string) error {
if err != nil { if err != nil {
return err return err
} }
if trip.StatusCode != http.StatusOK { if trip.StatusCode != http.StatusAccepted {
return fmt.Errorf("Trip response status code was not 200") return fmt.Errorf("Trip response status code was not 200")
} }
return nil return nil
@ -121,7 +121,7 @@ func (h *HttpAcmeProvider) authCheckRequest(method, url, domain, token, keyAuth
if err != nil { if err != nil {
return nil, err return nil, err
} }
if resp.StatusCode == http.StatusOK { if resp.StatusCode == http.StatusAccepted {
// just return // just return
return resp, nil return resp, nil
} }