Skip to content

add console message when number of adunits exceeds point #3707

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

Merged
merged 2 commits into from
Apr 5, 2019

Conversation

jsnellbaker
Copy link
Collaborator

Type of change

  • Feature

Description of change

This PR adds a console message when the number of adUnits for an auction exceeds a certain amount (currently set to 15). This is to help notify publishers of their setup and to potentially review it if the number seems incorrect or too high.

Copy link
Collaborator

@jaiminpanchal27 jaiminpanchal27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jsnellbaker Code looks good. Just one suggestion.

src/prebid.js Outdated
@@ -70,6 +70,11 @@ function setRenderSize(doc, width, height) {
}

export const checkAdUnitSetup = hook('sync', function (adUnits) {
let adUnitsLen = adUnits.length;
if (adUnitsLen > 15) {
utils.logInfo(`Current auction contains ${adUnitsLen} adUnits.`);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add auction id in the message as well ? It will help them track down everything related to auction.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated the log message to include some additional info. Please take a look.

@harpere harpere merged commit df312c1 into master Apr 5, 2019
jacekburys-quantcast pushed a commit to jacekburys-quantcast/Prebid.js that referenced this pull request May 15, 2019
* add console message when number of adunits exceeds point

* include additional information in log message
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants