Skip to content
This repository has been archived by the owner on Oct 21, 2024. It is now read-only.

Commit

Permalink
Do not initialize the analytics client if no write key set
Browse files Browse the repository at this point in the history
  • Loading branch information
laurentluce committed Aug 26, 2024
1 parent d4c093b commit d53f2ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kontrol-service/api/analytics.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const (

// NewAnalyticsWrapper creates a new AnalyticsWrapper
func NewAnalyticsWrapper(isDevMode bool, writeKey string) *AnalyticsWrapper {
if !isDevMode {
if !isDevMode && writeKey != "" {
// This is the Segment write key for the "kontrol-service" project. It is not
// a sensitive value, but it could be extracted to an env var in the future
// to separate dev and prod traffic if desired.
Expand Down

0 comments on commit d53f2ea

Please sign in to comment.