Skip to content

Commit

Permalink
Better warning on misconfigured end points.
Browse files Browse the repository at this point in the history
  • Loading branch information
antosarho committed May 16, 2024
1 parent 5426945 commit ba43c9b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion modules/prebidServerBidAdapter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,12 @@ function bidWonHandler(bid) {
}

function getMatchingConsentUrl(urlProp, gdprConsent) {
return hasPurpose1Consent(gdprConsent) ? urlProp.p1Consent : urlProp.noP1Consent;
const hasPurpose = hasPurpose1Consent(gdprConsent);
const url = hasPurpose ? urlProp.p1Consent : urlProp.noP1Consent
if (!url) {
logWarn('Missing matching consent URL when gdpr=' + hasPurpose);
}
return url;
}

function getConsentData(bidRequests) {
Expand Down

0 comments on commit ba43c9b

Please sign in to comment.