-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
if seatBidId is on bidResponse, always use it #4732
Conversation
@@ -224,7 +224,6 @@ const MOCK = { | |||
'transactionId': 'c116413c-9e3f-401a-bee1-d56aec29a1d4', | |||
'sizes': [[1000, 300], [970, 250], [728, 90]], | |||
'bidId': '3bd4ebb1c900e2', | |||
'seatBidId': 'aaaa-bbbb-cccc-dddd', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the mock of the bidRequestObject
, which would never have seatBidId
in it since seatBidId
is a bidResponse field.
So not realistic to have it here.
// RP server banner overwrites bidId with bid.seatBidId | ||
if (utils.deepAccess(bid, 'bidResponse.seatBidId') && bid.bidder === 'rubicon' && bid.source === 'server' && ['video', 'banner'].some(i => utils.deepAccess(bid, 'bidResponse.mediaType') === i)) { | ||
bid.seatBidId = bid.bidResponse.seatBidId; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The line bid.bidResponse = parseBidResponse(args, bid.bidResponse);
Adds seatBidId
to the internal bidResponse
in the analytics adapter. And if that is present, it overwrites the
internal bidRequest.bidId
which is sent to Analytics.
This bid.seatBidId
is not referenced or used anywhere else in the code.
So does not make sense to add it to this bid object.
Type of change
Description of change
For Rubicon analytics adapter if there is a
seatBidId
on the bidResponse object then we will be sure to use that as thebidId
we send to the batched endpoint.This is just removing a couple unnecessary checks and adding a test.