fix: do not return IAM/Bucket metadata replication errors to client (#16486)

This commit is contained in:
Harshavardhana
2023-01-27 00:41:54 +05:30
committed by GitHub
parent 1fd7946dce
commit d19cbc81b5
10 changed files with 84 additions and 189 deletions

View File

@@ -262,12 +262,6 @@ func (c *Client) Call(ctx context.Context, method string, values url.Values, bod
return nil, &NetworkError{err}
}
final := resp.Trailer.Get("FinalStatus")
if final != "" && final != "Success" {
defer xhttp.DrainBody(resp.Body)
return nil, errors.New(final)
}
if resp.StatusCode != http.StatusOK {
// If server returns 412 pre-condition failed, it would
// mean that authentication succeeded, but another