mirror of
https://codeberg.org/scip/esctl.git
synced 2026-08-24 12:24:17 +02:00
Compare commits
1 Commits
mapper
...
fix/api-re
| Author | SHA1 | Date | |
|---|---|---|---|
| e133d8b4b6 |
@@ -223,7 +223,7 @@ func CallAPI(conf *cfg.Config, verb, path, data string) ([]byte, error) {
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
if !conf.HumanCat && strings.HasPrefix(path, "/_cat") {
|
if !conf.HumanCat || (conf.HumanCat && !strings.HasPrefix(path, "/_cat")) {
|
||||||
req.Header.Add("Content-Type", "application/json")
|
req.Header.Add("Content-Type", "application/json")
|
||||||
req.Header.Add("Accept", "application/json")
|
req.Header.Add("Accept", "application/json")
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user