Skip to content

Commit

Permalink
correct send metric tags (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
mbotarro authored and cscatolini committed Feb 20, 2019
1 parent c245413 commit 3d02045
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions extensions/datadog_statsd.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,11 @@ func (s *StatsD) ReportMetricGauge(
}

if game != "" {
tags = append(tags, game)
tags = append(tags, fmt.Sprintf("game:%s", game))
}

if platform != "" {
tags = append(tags, platform)
tags = append(tags, fmt.Sprintf("platform:%s", platform))
}

s.Client.Gauge(metric, value, tags, 1)
Expand All @@ -157,11 +157,11 @@ func (s *StatsD) ReportMetricCount(
}

if game != "" {
tags = append(tags, game)
tags = append(tags, fmt.Sprintf("game:%s", game))
}

if platform != "" {
tags = append(tags, platform)
tags = append(tags, fmt.Sprintf("platform:%s", platform))
}

s.Client.Count(metric, value, tags, 1)
Expand Down

0 comments on commit 3d02045

Please sign in to comment.