Chore: Remove context.TODO() (#43409)

* Remove context.TODO() from services

* Fix live test

* Remove context.TODO
This commit is contained in:
idafurjes
2021-12-22 11:02:42 +01:00
committed by GitHub
parent 2409d8dc1f
commit b8852ef6a3
45 changed files with 133 additions and 126 deletions

View File

@@ -1,6 +1,7 @@
package api
import (
"context"
"errors"
"fmt"
"net/http"
@@ -41,7 +42,7 @@ func (srv TestingApiSrv) RouteTestRuleConfig(c *models.ReqContext, body apimodel
var path string
if datasourceID, err := strconv.ParseInt(recipient, 10, 64); err == nil {
ds, err := srv.DatasourceCache.GetDatasource(datasourceID, c.SignedInUser, c.SkipCache)
ds, err := srv.DatasourceCache.GetDatasource(context.Background(), datasourceID, c.SignedInUser, c.SkipCache)
if err != nil {
return ErrResp(http.StatusInternalServerError, err, "failed to get datasource")
}