For #27627 - Check the TCP CFR status lazily
Use lazyFeatureFlagPreference as a quick small way to avoid a race between initializing the value and the Nimbus initialization based on which the value should be calculated. This is the same flow that the other MR experiments use.
This commit is contained in:
parent
bc76907605
commit
50c8e56bd2
|
@ -610,9 +610,10 @@ class Settings(private val appContext: Context) : PreferencesHolder {
|
||||||
/**
|
/**
|
||||||
* Indicates if the total cookie protection CRF should be shown.
|
* Indicates if the total cookie protection CRF should be shown.
|
||||||
*/
|
*/
|
||||||
var shouldShowTotalCookieProtectionCFR by booleanPreference(
|
var shouldShowTotalCookieProtectionCFR by lazyFeatureFlagPreference(
|
||||||
appContext.getPreferenceKey(R.string.pref_key_should_show_total_cookie_protection_popup),
|
appContext.getPreferenceKey(R.string.pref_key_should_show_total_cookie_protection_popup),
|
||||||
default = mr2022Sections[Mr2022Section.TCP_CFR] == true,
|
featureFlag = true,
|
||||||
|
default = { mr2022Sections[Mr2022Section.TCP_CFR] == true },
|
||||||
)
|
)
|
||||||
|
|
||||||
val blockCookiesSelectionInCustomTrackingProtection by stringPreference(
|
val blockCookiesSelectionInCustomTrackingProtection by stringPreference(
|
||||||
|
|
Loading…
Reference in New Issue
Block a user