mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
client: deprecate client.CustomHTTPHeaders()
This function was added ina754d89b40
, but not used. Currently, the only consumer of this function I could find was docker/cli, which used it in a unit-test (this test has already been updated to not depend on this function); https://grep.app/search?q=.CustomHTTPHeaders%28%29&filter[lang][0]=Go Given that commita68ae4a2d9
deprecated the corresponding client.SetCustomHTTPHeaders() function, and because there is no active use for this function, it should be ok to deprecate. We can include this in a patch-release (to be sure nobody else is depending on it, and (if someone is) to notify them of the deprecation. As a follow-up to this commit, I'll remove both functions. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
5e498e20f7
commit
8afb57e633
1 changed files with 1 additions and 0 deletions
|
@ -282,6 +282,7 @@ func ParseHostURL(host string) (*url.URL, error) {
|
|||
}
|
||||
|
||||
// CustomHTTPHeaders returns the custom http headers stored by the client.
|
||||
// Deprecated: this function was unused, and will be removed in the next release.
|
||||
func (cli *Client) CustomHTTPHeaders() map[string]string {
|
||||
m := make(map[string]string)
|
||||
for k, v := range cli.customHTTPHeaders {
|
||||
|
|
Loading…
Reference in a new issue