From df861a1713833a7c9dfe36c5de539255080550e2 Mon Sep 17 00:00:00 2001 From: Samuel Dobbie Date: Tue, 30 Nov 2021 17:49:44 +0000 Subject: [PATCH] Fix GDPR consent choice capture --- modules/glimpseBidAdapter.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/modules/glimpseBidAdapter.js b/modules/glimpseBidAdapter.js index ea846c1a7b6..7bcf8cf3a7d 100644 --- a/modules/glimpseBidAdapter.js +++ b/modules/glimpseBidAdapter.js @@ -138,11 +138,16 @@ function getReferer(bidderRequest) { function getGdprConsentChoice(bidderRequest) { const hasGdprConsent = hasValue(bidderRequest) && - hasValue(bidderRequest.gdprConsent) && - hasStringValue(bidderRequest.gdprConsent.consentString) + hasValue(bidderRequest.gdprConsent) if (hasGdprConsent) { - return bidderRequest.gdprConsent + const gdprConsent = bidderRequest.gdprConsent + + return { + consentString: gdprConsent.consentString || '', + vendorData: gdprConsent.vendorData || {}, + gdprApplies: gdprConsent.gdprApplies || true, + } } return {