-
Notifications
You must be signed in to change notification settings - Fork 750
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
Adapter Name Case Insensitive: dealTier #3218
Changes from all commits
3060d15
b9ddd6e
b1783e5
bd353a0
fc673db
027ae48
ed3ee69
c5564e1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,7 +38,9 @@ func ReadDealTiersFromImp(imp openrtb2.Imp) (DealTierBidderMap, error) { | |
} | ||
for bidder, param := range impPrebidExt.Prebid.Bidders { | ||
if param.DealTier != nil { | ||
dealTiers[BidderName(bidder)] = *param.DealTier | ||
if bidderNormalized, bidderFound := NormalizeBidderName(bidder); bidderFound { | ||
dealTiers[bidderNormalized] = *param.DealTier | ||
} | ||
Comment on lines
+41
to
+43
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The deal tier map being created here from the original request has keys that are the normalized bidder names. This map is then used in There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good catch. Modified. |
||
} | ||
} | ||
|
||
|
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 line isn't covered by tests, do you think you can add a test where the bidder is not found from the
NormalizeBidderName
call?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.
Done. Also refactored
TestApplyDealSupport
a little bit.