mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
When introducing errorsource over in: https://github.com/grafana/grafana/pull/99900 I introduced a bug - trying to use a http response with a non-nil error. In that case, the response is nil, so code panics. This PR removes that check.
This commit is contained in:
parent
af8cab9210
commit
196a73ec72
@ -176,8 +176,7 @@ func execute(ctx context.Context, tracer trace.Tracer, dsInfo *models.Datasource
|
||||
res, err := dsInfo.HTTPClient.Do(request)
|
||||
if err != nil {
|
||||
return backend.DataResponse{
|
||||
Error: err,
|
||||
ErrorSource: backend.ErrorSourceFromHTTPStatus(res.StatusCode),
|
||||
Error: err,
|
||||
}, err
|
||||
}
|
||||
defer func() {
|
||||
|
Loading…
Reference in New Issue
Block a user