Skip to content

Commit

Permalink
Revert "CadentApertureMX Bid Adapter : GPP support for usersync endpo…
Browse files Browse the repository at this point in the history
…int (#13)"

This reverts commit 933dcd9.
  • Loading branch information
EMXDigital authored Aug 22, 2023
1 parent 933dcd9 commit e2dcd64
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 42 deletions.
10 changes: 1 addition & 9 deletions modules/cadentApertureMXBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ export const spec = {
}
return cadentBidResponses;
},
getUserSyncs: function (syncOptions, responses, gdprConsent, uspConsent, gppConsent) {
getUserSyncs: function (syncOptions, responses, gdprConsent, uspConsent) {
const syncs = [];
const consentParams = [];
if (syncOptions.iframeEnabled) {
Expand All @@ -390,14 +390,6 @@ export const spec = {
if (uspConsent && typeof uspConsent.consentString === 'string') {
consentParams.push(`usp=${uspConsent.consentString}`);
}
if(gppConsent && typeof gppConsent === 'object'){
if(gppConsent.gppString && typeof gppConsent.gppString === 'string'){
consentParams.push(`gpp=${gppConsent.gppString}`);
}
if(gppConsent.applicableSections && typeof gppConsent.applicableSections === 'object'){
consentParams.push(`gpp_sid=${gppConsent.applicableSections}`);
}
}
if (consentParams.length > 0) {
url = url + '?' + consentParams.join('&');
}
Expand Down
33 changes: 0 additions & 33 deletions test/spec/modules/cadentApertureMXBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -834,38 +834,5 @@ describe('cadent_aperture_mx Adapter', function () {
expect(syncs[0].url).to.contains('usp=test');
expect(syncs[0].url).to.equal('https://biddr.brealtime.com/check.html?gdpr=1&gdpr_consent=test&usp=test')
});

it('should pass gpp string and section id' , function(){
let syncs = spec.getUserSyncs({iframeEnabled: true}, {}, {},{}, {
gppString: 'abcdefgs',
applicableSections: [1,2,4]
});
expect(syncs).to.not.be.an('undefined');
expect(syncs[0].url).to.contains('gpp=abcdefgs')
expect(syncs[0].url).to.contains('gpp_sid=1,2,4')
});

it('should pass us_privacy and gdpr string and gpp string', function () {
let syncs = spec.getUserSyncs({ iframeEnabled: true }, {},
{
gdprApplies: true,
consentString: 'test'
},
{
consentString: 'test'
},
{
gppString: 'abcdefgs',
applicableSections: [1,2,4]
}
);
expect(syncs).to.not.be.an('undefined');
expect(syncs).to.have.lengthOf(1);
expect(syncs[0].type).to.equal('iframe');
expect(syncs[0].url).to.contains('gdpr=1');
expect(syncs[0].url).to.contains('usp=test');
expect(syncs[0].url).to.contains('gpp=abcdefgs');
expect(syncs[0].url).to.equal('https://biddr.brealtime.com/check.html?gdpr=1&gdpr_consent=test&usp=test&gpp=abcdefgs&gpp_sid=1,2,4');
});
});
});

0 comments on commit e2dcd64

Please sign in to comment.