Skip to content

Commit

Permalink
Getting whole bid from bidcpmadjustment function and then equalizing …
Browse files Browse the repository at this point in the history
…the bid currency to the converted currency
  • Loading branch information
Muhammad Ubaid Ashraf committed Jan 13, 2025
1 parent 7a210da commit bf59478
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/auction.js
Original file line number Diff line number Diff line change
Expand Up @@ -908,10 +908,11 @@ function setKeys(keyValues, bidderSettings, custBidObj, bidReq) {
}

export function adjustBids(bid) {
let bidPriceAdjusted = adjustCpm(bid.cpm, bid);
let bidPriceAdjusted = adjustCpm(bid, bid);

if (bidPriceAdjusted >= 0) {
bid.cpm = bidPriceAdjusted;
if (bidPriceAdjusted.cpm >= 0) {
bid.cpm = bidPriceAdjusted.cpm;
bid.currency = bidPriceAdjusted.currency
}
}

Expand Down

0 comments on commit bf59478

Please sign in to comment.