Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
DDuongNguyen committed Feb 14, 2024
1 parent 15f5d53 commit 9b9dec7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cmd/agent/subcommands/run/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ func startAgent(
}

// StopAgentWithDefaults is a temporary way for other packages to use stopAgent.
func StopAgentWithDefaults(server dogstatsdServer.Component, agentAPI internalAPI.Component) {
func StopAgentWithDefaults(agentAPI internalAPI.Component) {
stopAgent(&cliParams{GlobalParams: &command.GlobalParams{}}, agentAPI)
}

Expand Down
2 changes: 1 addition & 1 deletion cmd/agent/subcommands/run/command_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ func StartAgentWithDefaults(ctxChan <-chan context.Context) (<-chan error, error
collector collector.Component,
) error {

defer StopAgentWithDefaults(server, agentAPI)
defer StopAgentWithDefaults(agentAPI)

err := startAgent(
&cliParams{GlobalParams: &command.GlobalParams{}},
Expand Down
4 changes: 2 additions & 2 deletions pkg/serverless/metrics/metric.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (

// ServerlessMetricAgent represents the DogStatsD server and the aggregator
type ServerlessMetricAgent struct {
dogStatsDServer dogstatsdServer.Component
dogStatsDServer dogstatsdServer.ServerlessDogstatsd
tags []string
Demux aggregator.Demultiplexer

Expand Down Expand Up @@ -104,7 +104,7 @@ func (c *ServerlessMetricAgent) Flush() {
// Stop stops the DogStatsD server
func (c *ServerlessMetricAgent) Stop() {
if c.IsReady() {
c.Stop()
c.dogStatsDServer.Stop()
}
}

Expand Down

0 comments on commit 9b9dec7

Please sign in to comment.