2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-19 09:25:34 +00:00

[fenix] For https://github.com/mozilla-mobile/fenix/issues/927 - Adds build type to glean to report the channel

This commit is contained in:
Jeff Boek 2019-05-24 16:48:44 -07:00
parent e73188f04c
commit c98463e17a

View File

@ -23,6 +23,8 @@ import kotlinx.coroutines.Job
import kotlinx.coroutines.launch import kotlinx.coroutines.launch
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.runBlocking import kotlinx.coroutines.runBlocking
import mozilla.components.service.glean.BuildConfig
import mozilla.components.service.glean.config.Configuration
import org.mozilla.fenix.GleanMetrics.QrScanner import org.mozilla.fenix.GleanMetrics.QrScanner
import org.mozilla.fenix.GleanMetrics.Library import org.mozilla.fenix.GleanMetrics.Library
import org.mozilla.fenix.GleanMetrics.ErrorPage import org.mozilla.fenix.GleanMetrics.ErrorPage
@ -243,7 +245,7 @@ class GleanMetricsService(private val context: Context) : MetricsService {
starter = CoroutineScope(Dispatchers.Default).launch { starter = CoroutineScope(Dispatchers.Default).launch {
Glean.registerPings(Pings) Glean.registerPings(Pings)
Glean.initialize(context) Glean.initialize(context, Configuration(channel = BuildConfig.BUILD_TYPE))
Metrics.apply { Metrics.apply {
defaultBrowser.set(Browsers.all(context).isDefaultBrowser) defaultBrowser.set(Browsers.all(context).isDefaultBrowser)