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

ShareThrough Bid Adapter : fix playerSize #10011

Merged
merged 2 commits into from
May 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions modules/sharethroughBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,8 @@ export const sharethroughAdapterSpec = {
if (videoRequest) {
// default playerSize, only change this if we know width and height are properly defined in the request
let [w, h] = [640, 360];
if (videoRequest.playerSize && videoRequest.playerSize[0] && videoRequest.playerSize[1]) {
[w, h] = videoRequest.playerSize;
if (videoRequest.playerSize && videoRequest.playerSize[0] && videoRequest.playerSize[0][0] && videoRequest.playerSize[0][1]) {
[w, h] = videoRequest.playerSize[0];
}

impression.video = {
Expand Down
2 changes: 1 addition & 1 deletion test/spec/modules/sharethroughBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ describe('sharethrough adapter spec', function () {
api: [3],
mimes: ['video/3gpp'],
protocols: [2, 3],
playerSize: [640, 480],
playerSize: [[640, 480]],
startdelay: 42,
skipmin: 10,
skipafter: 20,
Expand Down