Skip to content

Commit

Permalink
ADS-4217 gdpr data in one level down
Browse files Browse the repository at this point in the history
  • Loading branch information
martiantim committed Aug 12, 2020
1 parent 323a60a commit e91efff
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions modules/mavenAnalyticsAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,14 @@ let mavenAnalytics = Object.assign(adapter({hummingbirdUrl, analyticsType}), {
// GDPR values are stored with at the bidRequest level
// If set for any bidRequest, set for auction
args.bidderRequests.forEach(request => {
if (request.hasOwnProperty('gdprApplies')) {
auctionObj.gdprApplies = request.gdprApplies;
}
if (request.hasOwnProperty('consentString')) {
auctionObj.consentString = request.consentString;
if (request.gdprConsent) {
let gc = request.gdprConsent;
if (gc.hasOwnProperty('gdprApplies')) {
auctionObj.gdprApplies = gc.gdprApplies;
}
if (gc.hasOwnProperty('consentString')) {
auctionObj.consentString = gc.consentString;
}
}
});
currentAuctions[id] = auctionObj;
Expand Down

0 comments on commit e91efff

Please sign in to comment.