Skip to content

Commit

Permalink
Change the EU consent string parameter name to the company-wide stand…
Browse files Browse the repository at this point in the history
…ard (#6320)
  • Loading branch information
slimkrazy authored Feb 18, 2021
1 parent cfe4464 commit 0939147
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion modules/verizonMediaIdSystem.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export const verizonMediaIdSubmodule = {
'1p': includes([1, '1', true], params['1p']) ? '1' : '0',
he: params.he,
gdpr: isEUConsentRequired(consentData) ? '1' : '0',
euconsent: isEUConsentRequired(consentData) ? consentData.gdpr.consentString : '',
gdpr_consent: isEUConsentRequired(consentData) ? consentData.gdpr.consentString : '',
us_privacy: consentData && consentData.uspConsent ? consentData.uspConsent : ''
};

Expand Down
8 changes: 4 additions & 4 deletions test/spec/modules/verizonMediaIdSystem_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ describe('Verizon Media ID Submodule', () => {
pixelId: PIXEL_ID,
'1p': '0',
gdpr: '1',
euconsent: consentData.gdpr.consentString,
gdpr_consent: consentData.gdpr.consentString,
us_privacy: consentData.uspConsent
};
const requestQueryParams = utils.parseQS(ajaxStub.firstCall.args[0].split('?')[1]);
Expand All @@ -107,7 +107,7 @@ describe('Verizon Media ID Submodule', () => {
he: HASHED_EMAIL,
'1p': '0',
gdpr: '1',
euconsent: consentData.gdpr.consentString,
gdpr_consent: consentData.gdpr.consentString,
us_privacy: consentData.uspConsent
};
const requestQueryParams = utils.parseQS(ajaxStub.firstCall.args[0].split('?')[1]);
Expand All @@ -134,7 +134,7 @@ describe('Verizon Media ID Submodule', () => {

const requestQueryParams = utils.parseQS(ajaxStub.firstCall.args[0].split('?')[1]);
expect(requestQueryParams.gdpr).to.equal('1');
expect(requestQueryParams.euconsent).to.equal(consentData.gdpr.consentString);
expect(requestQueryParams.gdpr_consent).to.equal(consentData.gdpr.consentString);
});

it('sets GDPR consent data flag correctly when call is NOT under GDPR jurisdiction.', () => {
Expand All @@ -147,7 +147,7 @@ describe('Verizon Media ID Submodule', () => {

const requestQueryParams = utils.parseQS(ajaxStub.firstCall.args[0].split('?')[1]);
expect(requestQueryParams.gdpr).to.equal('0');
expect(requestQueryParams.euconsent).to.equal('');
expect(requestQueryParams.gdpr_consent).to.equal('');
});

[1, '1', true].forEach(firstPartyParamValue => {
Expand Down

0 comments on commit 0939147

Please sign in to comment.