Skip to content

Commit f24971c

Browse files
committed
Fix Prebid.js integration to work with prebid.js v7.0.0 and later, which includes changes to how bidder settings are configured.
1 parent a9569b6 commit f24971c

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

  • crates/js/lib/src/integrations/prebid

crates/js/lib/src/integrations/prebid/index.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,16 @@ export function installPrebidNpm(config?: Partial<PrebidNpmConfig>): typeof pbjs
242242
}
243243
pbjs.setConfig(pbjsConfig as PbjsConfig);
244244

245+
// Allow the trustedServer adapter to return bids under the real bidder codes
246+
// (e.g. "mocktioneer", "appnexus") from the server-side seat.
247+
pbjs.bidderSettings = {
248+
...(pbjs.bidderSettings || {}),
249+
[ADAPTER_CODE]: {
250+
...(pbjs.bidderSettings?.[ADAPTER_CODE] || {}),
251+
allowAlternateBidderCodes: true,
252+
},
253+
};
254+
245255
// processQueue() must be called after all modules are loaded when using
246256
// prebid.js via NPM.
247257
pbjs.processQueue();

0 commit comments

Comments
 (0)