Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verizon Media ID System: Changed EU consent string parameter name to gdpr_consent #6320

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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