-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Adxcg adapter #1554
Adxcg adapter #1554
Conversation
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.
@adxcgcom Thanks for submitting adapter. Left some comments.
modules/adxcgBidAdapter.js
Outdated
}); | ||
}; | ||
|
||
function removeUrlParameters(oldURL) { |
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 function can be removed and you can use functions from url.js
modules/adxcgBidAdapter.js
Outdated
sizes.push(parsedSizes); | ||
}); | ||
|
||
let secure = window.location.protocol == 'https:'; |
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.
utils.getTopWindowLocation() get location object and also handles cross domain environments. Would recommend using that one.
modules/adxcgBidAdapter.js
Outdated
return newURL; | ||
} | ||
|
||
function parseWidthAndHeight(bid) { |
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.
check if utils.parseSizesInput() fits your needs. If it does you can remove this function too.
modules/adxcgBidAdapter.js
Outdated
bid.width = adxcgBidReponse.width; | ||
bid.height = adxcgBidReponse.height; | ||
|
||
utils.logMessage('submitting bid[' + bidRequest.placementCode + ']:' + JSON.stringify(bid)); |
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.
We prefer to use https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals at all places.
…ons and replaced them with those from prebid utils.js and url.js. Enabled credentials in the ajax call. Replaced string concatenations with template literals where possible. Escaped native click url in order to correctly handle redirects.
Thank you for the review, all issues should be addressed in the latest commit. |
LGTM |
}; | ||
|
||
adaptermanager.registerBidAdapter(new AdxcgAdapter(), 'adxcg', { | ||
supportedMediaTypes: ['video', 'native'] |
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.
Awesome!
* added adxcg adapter and associated tests * Removed unnecessary string concatenations and similar utilitiy functions and replaced them with those from prebid utils.js and url.js. Enabled credentials in the ajax call. Replaced string concatenations with template literals where possible. Escaped native click url in order to correctly handle redirects.
* tag '0.28.0' of https://github.com/prebid/Prebid.js: (27 commits) Prebid 0.28.0 Release Revert "Upgrade sinon to 3.x (prebid#1491)" (prebid#1563) add () for correct order of operations in scaling increments for currency (prebid#1559) AppnexusAst adapter update: Added source and version to request payload (prebid#1555) remove unnecessary spread operator (prebid#1561) Adxcg adapter (prebid#1554) Upgrade sinon to 3.x (prebid#1491) Rename vastPayload to vastXml (prebid#1556) Single-size sizes array now can be taken, too (prebid#1535) Updated the istanbul-instrumenter-loader (prebid#1550) Add AerServ Adapter (prebid#1538) Fixed imports and made adform support aliasing (prebid#1518) Custom granularity fix (prebid#1546) Fix `documentation lint` issues (prebid#1544) Yieldbot adunit bidder params slot name usage fix (prebid#1394) Update serverbid adapter to use smartsync (prebid#1324) Add improvedigitalBidAdapter (prebid#1381) Fix prebid#1533 spring server typo (prebid#1542) userSync is off by default (prebid#1543) currency module (prebid#1374) ...
* added adxcg adapter and associated tests * Removed unnecessary string concatenations and similar utilitiy functions and replaced them with those from prebid utils.js and url.js. Enabled credentials in the ajax call. Replaced string concatenations with template literals where possible. Escaped native click url in order to correctly handle redirects.
….28.0 to aolgithub-master * commit '4d9ade3df767750743f8888ed9efd6c77f8d0050': (26 commits) Added changelog entry. Added new aol partners ids. Prebid 0.28.0 Release Revert "Upgrade sinon to 3.x (prebid#1491)" (prebid#1563) add () for correct order of operations in scaling increments for currency (prebid#1559) AppnexusAst adapter update: Added source and version to request payload (prebid#1555) remove unnecessary spread operator (prebid#1561) Adxcg adapter (prebid#1554) Upgrade sinon to 3.x (prebid#1491) Rename vastPayload to vastXml (prebid#1556) Single-size sizes array now can be taken, too (prebid#1535) Updated the istanbul-instrumenter-loader (prebid#1550) Add AerServ Adapter (prebid#1538) Fixed imports and made adform support aliasing (prebid#1518) Custom granularity fix (prebid#1546) Fix `documentation lint` issues (prebid#1544) Yieldbot adunit bidder params slot name usage fix (prebid#1394) Update serverbid adapter to use smartsync (prebid#1324) Add improvedigitalBidAdapter (prebid#1381) Fix prebid#1533 spring server typo (prebid#1542) ...
* added adxcg adapter and associated tests * Removed unnecessary string concatenations and similar utilitiy functions and replaced them with those from prebid utils.js and url.js. Enabled credentials in the ajax call. Replaced string concatenations with template literals where possible. Escaped native click url in order to correctly handle redirects.
Type of change
Description of change
Adding adxcg adapter and its tests