Merge pull request #6566 from influxdata/nc-0.13-client-err

Cherry pick #6565 into 0.13
pull/6577/head
Nathaniel Cook 2016-05-05 16:51:48 -06:00
commit fad057d9b7
1 changed files with 1 additions and 1 deletions

View File

@ -576,7 +576,7 @@ func (c *client) Query(q Query) (*Response, error) {
}
// If we got a valid decode error, send that back
if decErr != nil {
return nil, decErr
return nil, fmt.Errorf("unable to decode json: received status code %d err: %s", resp.StatusCode, decErr)
}
// If we don't have an error in our json response, and didn't get statusOK
// then send back an error