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

Core: Adding useBaseGvlid to aliasBidAdapter #12247

Merged
merged 2 commits into from
Sep 19, 2024
Merged

Conversation

mkomorski
Copy link
Collaborator

Type of change

  • Bugfix

  • Feature

  • New bidder adapter

  • Updated bidder adapter

  • Code style update (formatting, local variables)

  • Refactoring (no functional changes, no api changes)

  • Build related changes

  • CI related changes

  • Does this change affect user-facing APIs or examples documented on http://prebid.org?

  • Other

Description of change

Other information

#10759

@mkomorski mkomorski changed the title Adding useBaseGvlid to aliasBidAdapter Core: Adding useBaseGvlid to aliasBidAdapter Sep 16, 2024
Copy link
Collaborator

@dgirardi dgirardi left a comment

Choose a reason for hiding this comment

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

@@ -1630,6 +1630,16 @@ describe('adapterManager tests', function () {
expect(adapterManager.videoAdapters).to.include(alias);
}
});

it('should use gvlid of original adapter when option set', () => {
const mediaType = FEATURES.VIDEO ? 'video' : 'banner'
Copy link
Collaborator

Choose a reason for hiding this comment

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

This doesn't seem necessary - you're not testing anything about media types.

let gvlid = options && options.gvlid;
if (spec.gvlid != null && gvlid == null) {
const gvlid = useBaseGvlid ? spec.gvlid : options?.gvlid;
if (!useBaseGvlid && spec.gvlid != null && options?.gvlid == null) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
if (!useBaseGvlid && spec.gvlid != null && options?.gvlid == null) {
if (gvlid == null && spec.gvlid != null) {

@ChrisHuie ChrisHuie self-assigned this Sep 19, 2024
@ChrisHuie ChrisHuie merged commit 9a06e30 into master Sep 19, 2024
6 checks passed
@ChrisHuie ChrisHuie deleted the mkomorski/useBaseGvlid branch September 19, 2024 18:44
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.

3 participants