Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issue panic without any command fix #711

Merged
merged 1 commit into from
May 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
issue panic without any command fix
james03160927 committed May 24, 2024
commit cb1a5f86f290f6128a392ff259320e022fcafbf6
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
@@ -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) {