forked from TrueCloudLab/lego
pdns: fix notify (#1983)
This commit is contained in:
parent
3cefc7a51b
commit
35c259e91d
1 changed files with 2 additions and 1 deletions
|
@ -218,7 +218,8 @@ func newJSONRequest(ctx context.Context, method string, endpoint *url.URL, paylo
|
|||
|
||||
req.Header.Set("Accept", "application/json")
|
||||
|
||||
if payload != nil {
|
||||
// PowerDNS doesn't follow HTTP convention about the "Content-Type" header.
|
||||
if method != http.MethodGet && method != http.MethodDelete {
|
||||
req.Header.Set("Content-Type", "application/json")
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue