Skip to content

Commit

Permalink
issue panic without any command fix (gruntwork-io#711)
Browse files Browse the repository at this point in the history
  • Loading branch information
james03160927 authored May 27, 2024
1 parent fea2058 commit 133837c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions telemetry/telemetry.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
package telemetry

import (
"github.com/gruntwork-io/go-commons/telemetry"
"os"

"github.com/gruntwork-io/go-commons/telemetry"
)

var sendTelemetry = true
Expand All @@ -16,9 +17,11 @@ func InitTelemetry(name string, version string) {
isCircleCi = os.Getenv("CIRCLECI") == "true"
sendTelemetry = !disableTelemetryFlag
if sendTelemetry {
cmd = os.Args[1]
telemetryClient = telemetry.NewMixPanelTelemetryClient("https://t.gruntwork.io/", name, version)
}
if len(os.Args) > 1 {
cmd = os.Args[1]
}
}

func SetAccountId(accountId string) {
Expand Down

0 comments on commit 133837c

Please sign in to comment.