From 1e25e2942193bc090f14a7c80d6b1976d1de200e Mon Sep 17 00:00:00 2001 From: Robert Ray Martinez III Date: Mon, 15 May 2023 12:20:26 -0700 Subject: [PATCH] Revert "Rubicon Bid Adapter : access x_source.tid from ortb2 object (#9940)" (#9953) This reverts commit ba6a97fe81fc9ff44144e7ac8d3b5edae0a58b72. --- modules/rubiconBidAdapter.js | 2 +- test/spec/modules/rubiconBidAdapter_spec.js | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/modules/rubiconBidAdapter.js b/modules/rubiconBidAdapter.js index 041dd5bcc99..62ec61b3dcf 100644 --- a/modules/rubiconBidAdapter.js +++ b/modules/rubiconBidAdapter.js @@ -466,7 +466,7 @@ export const spec = { 'rp_floor': (params.floor = parseFloat(params.floor)) >= 0.01 ? params.floor : undefined, 'rp_secure': '1', 'tk_flint': `${rubiConf.int_type || DEFAULT_INTEGRATION}_v$prebid.version$`, - 'x_source.tid': deepAccess(bidderRequest, 'ortb2.source.tid'), + 'x_source.tid': bidRequest.transactionId, 'x_imp.ext.tid': bidRequest.transactionId, 'l_pb_bid_id': bidRequest.bidId, 'p_screen_res': _getScreenResolution(), diff --git a/test/spec/modules/rubiconBidAdapter_spec.js b/test/spec/modules/rubiconBidAdapter_spec.js index 048c68f44e7..4f1c0dd606a 100644 --- a/test/spec/modules/rubiconBidAdapter_spec.js +++ b/test/spec/modules/rubiconBidAdapter_spec.js @@ -89,7 +89,6 @@ describe('the rubicon adapter', function () { bidderCode: 'rubicon', auctionId: 'c45dd708-a418-42ec-b8a7-b70a6c6fab0a', bidderRequestId: '178e34bad3658f', - ortb2: { source: { tid: 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b' } }, bids: [ { bidder: 'rubicon', @@ -347,7 +346,6 @@ describe('the rubicon adapter', function () { transactionId: 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b' } ], - ortb2: { source: { tid: 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b' } }, start: 1472239426002, auctionStart: 1472239426000, timeout: 5000 @@ -621,6 +619,7 @@ describe('the rubicon adapter', function () { 'rand': '0.1', 'tk_flint': INTEGRATION, 'x_source.tid': 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b', + 'x_imp.ext.tid': 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b', 'p_screen_res': /\d+x\d+/, 'tk_user_key': '12346', 'kw': 'a,b,c', @@ -2277,8 +2276,6 @@ describe('the rubicon adapter', function () { }); describe('createSlotParams', function () { - const localBidderRequest = Object.assign({}, bidderRequest); - localBidderRequest.ortb2 = {source: {tid: 'faked707-a418-42ec-b8a7-b70a6c6fab0b'}}; it('should return a valid slot params object', function () { let expectedQuery = { 'account_id': '14062', @@ -2289,8 +2286,7 @@ describe('the rubicon adapter', function () { 'p_pos': 'atf', 'rp_secure': /[01]/, 'tk_flint': INTEGRATION, - 'x_source.tid': 'faked707-a418-42ec-b8a7-b70a6c6fab0b', - 'x_imp.ext.tid': 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b', + 'x_source.tid': 'd45dd707-a418-42ec-b8a7-b70a6c6fab0b', 'p_screen_res': /\d+x\d+/, 'tk_user_key': '12346', 'kw': 'a,b,c', @@ -2303,7 +2299,7 @@ describe('the rubicon adapter', function () { 'rf': 'localhost' }; - const slotParams = spec.createSlotParams(bidderRequest.bids[0], localBidderRequest); + const slotParams = spec.createSlotParams(bidderRequest.bids[0], bidderRequest); // test that all values above are both present and correct Object.keys(expectedQuery).forEach(key => {