diff --git a/receiver/datadogreceiver/internal/translator/service_check_translator_test.go b/receiver/datadogreceiver/internal/translator/service_check_translator_test.go index ad5b29411194..3600f2bda81b 100644 --- a/receiver/datadogreceiver/internal/translator/service_check_translator_test.go +++ b/receiver/datadogreceiver/internal/translator/service_check_translator_test.go @@ -7,12 +7,11 @@ import ( "encoding/json" "testing" - "go.opentelemetry.io/collector/pdata/pcommon" - "github.com/DataDog/datadog-api-client-go/v2/api/datadogV1" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/pdata/pcommon" "go.opentelemetry.io/collector/pdata/pmetric" ) diff --git a/receiver/datadogreceiver/receiver.go b/receiver/datadogreceiver/receiver.go index a93a515a60c0..b975ce3dd40e 100644 --- a/receiver/datadogreceiver/receiver.go +++ b/receiver/datadogreceiver/receiver.go @@ -207,9 +207,9 @@ func (ddr *datadogReceiver) handleCheckRun(w http.ResponseWriter, req *http.Requ return } - var services []translator.ServiceCheck + var services []translator.ServiceCheck - err = json.Unmarshal(buf.Bytes(), &services) + err = json.Unmarshal(buf.Bytes(), &services) if err != nil { http.Error(w, err.Error(), http.StatusBadRequest) ddr.params.Logger.Error(err.Error()) diff --git a/receiver/datadogreceiver/receiver_test.go b/receiver/datadogreceiver/receiver_test.go index 9e9e29994acd..0bdca1f559ec 100644 --- a/receiver/datadogreceiver/receiver_test.go +++ b/receiver/datadogreceiver/receiver_test.go @@ -176,7 +176,7 @@ func TestDatadogServices_EndToEnd(t *testing.T) { dd, err := newDataDogReceiver( cfg, - receivertest.NewNopCreateSettings(), + receivertest.NewNopSettings(), ) require.NoError(t, err, "Must not error when creating receiver") dd.(*datadogReceiver).nextMetricsConsumer = sink