diff --git a/core/analytics/src/google/kotlin/org/meshtastic/core/analytics/platform/GooglePlatformAnalytics.kt b/core/analytics/src/google/kotlin/org/meshtastic/core/analytics/platform/GooglePlatformAnalytics.kt index ab62aa723..412fed033 100644 --- a/core/analytics/src/google/kotlin/org/meshtastic/core/analytics/platform/GooglePlatformAnalytics.kt +++ b/core/analytics/src/google/kotlin/org/meshtastic/core/analytics/platform/GooglePlatformAnalytics.kt @@ -102,7 +102,15 @@ constructor( .setBundleWithTraceEnabled(true) .setBundleWithRumEnabled(true) .build() - Timber.plant(DatadogTree(datadogLogger), CrashlyticsTree(), DebugTree()) + buildList { + add(DatadogTree(datadogLogger)) + add(CrashlyticsTree()) + if (BuildConfig.DEBUG) { + add(DebugTree()) + } + } + .forEach(Timber::plant) + // Initial consent state updateAnalyticsConsent(analyticsPrefs.analyticsAllowed)