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

adding Prebid.js version to request in quantcastBidAdapter #3230

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
5 changes: 3 additions & 2 deletions modules/quantcastBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export const spec = {
});
});

const gdprConsent = bidderRequest ? bidderRequest.gdprConsent : {};
const gdprConsent = (bidderRequest && bidderRequest.gdprConsent) ? bidderRequest.gdprConsent : {};

// Request Data Format can be found at https://wiki.corp.qc/display/adinf/QCX
const requestData = {
Expand All @@ -92,7 +92,8 @@ export const spec = {
},
bidId: bid.bidId,
gdprSignal: gdprConsent.gdprApplies ? 1 : 0,
gdprConsent: gdprConsent.consentString
gdprConsent: gdprConsent.consentString,
prebidJsVersion: pbjs.version
jacekburys-quantcast marked this conversation as resolved.
Show resolved Hide resolved
};

const data = JSON.stringify(requestData);
Expand Down
3 changes: 2 additions & 1 deletion test/spec/modules/quantcastBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ describe('Quantcast adapter', function () {
domain
},
bidId: '2f7b179d443f14',
gdprSignal: 0
gdprSignal: 0,
prebidJsVersion: pbjs.version
jacekburys-quantcast marked this conversation as resolved.
Show resolved Hide resolved
};

expect(requests[0].data).to.equal(JSON.stringify(expectedBidRequest));
Expand Down