Skip to content
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

Beachfront adapter - add ad unit size #1183

Merged
merged 21 commits into from
May 19, 2017
Merged
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
f4496ee
Added ad unit size to bid request
May 8, 2017
e77418e
Merge branch 'master' into update-beachfront-adapter
May 18, 2017
f392a6c
Fixed lint errors
May 19, 2017
3b0082b
Added ad unit size to bid request
May 8, 2017
3c2027a
Add trafficSourceCode + test (#1184)
May 8, 2017
b2798f4
Prebid 0.23.1 Release
May 8, 2017
c358ebe
pre release version bump
May 9, 2017
c73e458
inclusion of popular Nordic ad sizes to default size list (#1168)
May 10, 2017
cb67cf8
Add PubWise Analytics (#1151)
GLStephen May 15, 2017
c7a3d8e
add new rp_secure param to rubicon adapter (#1190)
snapwich May 15, 2017
b68af07
Add type conversion into PrebidServer to handle inconsistent types. (…
May 16, 2017
21d8a22
Bug fix: bids served by secure creatives does not get pushed into _wi…
canyousayyes May 16, 2017
bd169bf
Add dynamic bidfloor parameter to Smart Adserver Adapter (#1194)
May 17, 2017
e8be4ac
Upgrade linters to ESLint with stricter code style (#1111)
matthewlane May 17, 2017
73d5bf6
Add Support for DigiTrust in Rubicon Adapter (#1201)
grevory May 17, 2017
4f072e3
HIRO Media: Remove batching mechanism and use AJAX instead of JSONP (…
ronenst May 17, 2017
b025d54
Rename secureCreatives file and lint (#1203)
grevory May 18, 2017
95bbfc5
Common user-sync (#1144)
ckbo3hrk May 18, 2017
6f4f4d4
updated tag (#1212)
jaiminpanchal27 May 18, 2017
420d921
Merge branch 'update-beachfront-adapter' of https://github.com/bfmdep…
May 19, 2017
d4f299c
Changed “bidRequest” to “bid” for clarity
May 19, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions src/adapters/beachfront.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function BeachfrontAdapter() {
const bids = bidRequests.bids || [];
bids.forEach(function(bid) {
var bidRequest = getBidRequest(bid);
var RTBDataParams = prepareAndSaveRTBRequestParams(bid);
var RTBDataParams = prepareAndSaveRTBRequestParams(bidRequest);
Copy link
Member

@mkendall07 mkendall07 May 19, 2017

Choose a reason for hiding this comment

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

I think this should still be bid ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I changed it to bidRequest because it has the parsed width and height properties.

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

bid.params should exist. I think the confusion here is that bid and bidRequest are referencing the same object. I can revert that line if it makes it more clear.

Copy link
Member

Choose a reason for hiding this comment

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

Oh right. Yeah that's a bit confusing... I would just make it bid to clear that up

Copy link
Member

Choose a reason for hiding this comment

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

I'll merge when you make the change

if (!RTBDataParams) {
var error = "No bid params";
utils.logError(error);
Expand Down Expand Up @@ -52,12 +52,15 @@ function BeachfrontAdapter() {
return ((/(ios|ipod|ipad|iphone|android)/i).test(global.navigator.userAgent) ? 1 : ((/(smart[-]?tv|hbbtv|appletv|googletv|hdmi|netcast\.tv|viera|nettv|roku|\bdtv\b|sonydtv|inettvbrowser|\btv\b)/i).test(global.navigator.userAgent) ? 1 : 2));
}

var bidRequestObject = {
var bidRequestObject = {
isPrebid: true,
appId: bid.params.appId,
domain: document.location.hostname,
imp:[{
video:{},
video: {
w: bid.width,
h: bid.height
},
bidfloor: bid.params.bidfloor
}],
site:{
Expand Down