Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gaba
fenix
Commits
c58fa028
Commit
c58fa028
authored
Aug 25, 2020
by
Jeff Boek
Committed by
Jonathan Almeida
Aug 26, 2020
Browse files
For #13368 - Ignores strict mode for LeanplumMetricsService
parent
c8e97546
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/src/main/java/org/mozilla/fenix/components/metrics/LeanplumMetricsService.kt
View file @
c58fa028
...
...
@@ -7,6 +7,7 @@ package org.mozilla.fenix.components.metrics
import
android.app.Application
import
android.content.Context.MODE_PRIVATE
import
android.net.Uri
import
android.os.StrictMode
import
android.util.Log
import
androidx.annotation.VisibleForTesting
import
com.leanplum.Leanplum
...
...
@@ -22,6 +23,7 @@ import kotlinx.coroutines.withContext
import
mozilla.components.support.locale.LocaleManager
import
org.mozilla.fenix.BuildConfig
import
org.mozilla.fenix.components.metrics.MozillaProductDetector.MozillaProducts
import
org.mozilla.fenix.ext.resetPoliciesAfter
import
org.mozilla.fenix.ext.settings
import
org.mozilla.fenix.home.intent.DeepLinkIntentProcessor
import
java.util.Locale
...
...
@@ -81,7 +83,9 @@ class LeanplumMetricsService(
override
val
type
=
MetricServiceType
.
Marketing
private
val
token
=
Token
(
LeanplumId
,
LeanplumToken
)
private
val
preferences
=
application
.
getSharedPreferences
(
PREFERENCE_NAME
,
MODE_PRIVATE
)
private
val
preferences
=
StrictMode
.
allowThreadDiskReads
().
resetPoliciesAfter
{
application
.
getSharedPreferences
(
PREFERENCE_NAME
,
MODE_PRIVATE
)
}
@VisibleForTesting
internal
val
deviceId
by
lazy
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment