You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In some cases a server may return an error on the ping response but
still provide version details. The client should use these values when
available.
Signed-off-by: Brian Goff <[email protected]>
returnserverResp, fmt.Errorf("Error: request returned %s for API route and version %s, check if the server supports the requested API version", http.StatusText(serverResp.statusCode), req.URL)
returnfmt.Errorf("Error: request returned %s for API route and version %s, check if the server supports the requested API version", http.StatusText(serverResp.statusCode), serverResp.reqURL)
207
+
}
204
208
205
-
returnserverResp, fmt.Errorf("Error response from daemon: %s", strings.TrimSpace(errorMessage))
209
+
varctstring
210
+
ifserverResp.header!=nil {
211
+
ct=serverResp.header.Get("Content-Type")
206
212
}
207
213
208
-
serverResp.body=resp.Body
209
-
serverResp.header=resp.Header
210
-
returnserverResp, nil
214
+
varerrorMessagestring
215
+
if (cli.version==""||versions.GreaterThan(cli.version, "1.23")) &&ct=="application/json" {
0 commit comments