Skip to content

Commit

Permalink
Pubmatic add warning for non-string adSlots (#6304)
Browse files Browse the repository at this point in the history
* add warning for non-string adSlots

- and update the markdown file to say they should be strings

* be more specific in explanatory comment
  • Loading branch information
jsut authored Feb 16, 2021
1 parent a55b1ad commit c94ee67
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions modules/pubmaticBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,9 @@ function _cleanSlot(slotName) {
if (utils.isStr(slotName)) {
return slotName.replace(/^\s+/g, '').replace(/\s+$/g, '');
}
if (slotName) {
utils.logWarn(BIDDER_CODE + ': adSlot must be a string. Ignoring adSlot');
}
return '';
}

Expand Down
4 changes: 2 additions & 2 deletions modules/pubmaticBidAdapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ var adUnits = [
bids: [{
bidder: 'pubmatic',
params: {
publisherId: '156209', // required, must be wrapped in quotes
publisherId: '156209', // required, must be a string, not an integer or other js type.
oustreamAU: 'renderer_test_pubmatic', // required if mediaTypes-> video-> context is 'outstream' and optional if renderer is defined in adUnits or in mediaType video. This value can be get by BlueBillyWig Team.
adSlot: 'pubmatic_test2', // optional
adSlot: 'pubmatic_test2', // optional, must be a string, not an integer or other js type.
pmzoneid: 'zone1, zone11', // optional
lat: '40.712775', // optional
lon: '-74.005973', // optional
Expand Down

0 comments on commit c94ee67

Please sign in to comment.