diff --git a/ui/pages/settings/security-tab/security-tab.component.js b/ui/pages/settings/security-tab/security-tab.component.js index f9e854ff2465..fe9785f5e4c1 100644 --- a/ui/pages/settings/security-tab/security-tab.component.js +++ b/ui/pages/settings/security-tab/security-tab.component.js @@ -381,14 +381,15 @@ export default class SecurityTab extends PureComponent { { - setDataCollectionForMarketing(!value); + const newMarketingConsent = Boolean(!value); + setDataCollectionForMarketing(newMarketingConsent); if (participateInMetaMetrics) { this.context.trackEvent({ category: MetaMetricsEventCategory.Settings, event: MetaMetricsEventName.AnalyticsPreferenceSelected, properties: { is_metrics_opted_in: true, - has_marketing_consent: false, + has_marketing_consent: Boolean(newMarketingConsent), location: 'Settings', }, });