diff --git a/dotcom-rendering/src/lib/contributions.ts b/dotcom-rendering/src/lib/contributions.ts index f5024a2b58..fc7276ab32 100644 --- a/dotcom-rendering/src/lib/contributions.ts +++ b/dotcom-rendering/src/lib/contributions.ts @@ -6,9 +6,9 @@ import type { DCRFrontType } from '../types/front'; import type { DCRNewslettersPageType } from '../types/newslettersPage'; import type { DCRTagPageType } from '../types/tagPage'; -// User Attributes API cookies (created on sign-in) +// User Attributes API cookie (created on sign-in) export const HIDE_SUPPORT_MESSAGING_COOKIE = 'gu_hide_support_messaging'; -export const RECURRING_CONTRIBUTOR_COOKIE = 'gu_recurring_contributor'; + export const OPT_OUT_OF_ARTICLE_COUNT_COOKIE = 'gu_article_count_opt_out'; // Local storage keys diff --git a/dotcom-rendering/src/lib/readerRevenueDevUtils.ts b/dotcom-rendering/src/lib/readerRevenueDevUtils.ts index 53f2975ab7..5d4053b873 100644 --- a/dotcom-rendering/src/lib/readerRevenueDevUtils.ts +++ b/dotcom-rendering/src/lib/readerRevenueDevUtils.ts @@ -1,16 +1,8 @@ import { getCookie, removeCookie, setCookie, storage } from '@guardian/libs'; -import { - HIDE_SUPPORT_MESSAGING_COOKIE, - RECURRING_CONTRIBUTOR_COOKIE, - SUPPORT_ONE_OFF_CONTRIBUTION_COOKIE, -} from './contributions'; +import { HIDE_SUPPORT_MESSAGING_COOKIE } from './contributions'; import { getLocaleCode } from './getCountryCode'; -const readerRevenueCookies = [ - HIDE_SUPPORT_MESSAGING_COOKIE, - RECURRING_CONTRIBUTOR_COOKIE, - SUPPORT_ONE_OFF_CONTRIBUTION_COOKIE, -]; +const readerRevenueCookies = [HIDE_SUPPORT_MESSAGING_COOKIE]; const clearEpicViewLog = (): void => storage.local.remove('gu.contributions.views'); @@ -22,12 +14,6 @@ const clearBannerLastClosedAt = (): void => { storage.local.remove('gu.noRRBannerTimestamp'); }; -const fakeOneOffContributor = (): void => - setCookie({ - name: SUPPORT_ONE_OFF_CONTRIBUTION_COOKIE, - value: Date.now().toString(), - }); - const MULTIVARIATE_ID_COOKIE = 'GU_mvt_id'; const MAX_CLIENT_MVT_ID = 1000000; const incrementMvtCookie = (): void => { @@ -76,10 +62,6 @@ const clearCommonReaderRevenueStateAndReload = ( for (const cookie of readerRevenueCookies) removeCookie({ name: cookie }); clearEpicViewLog(); - if (asExistingSupporter) { - fakeOneOffContributor(); - } - window.location.reload(); };