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

Default auction type was defined as 1 #2

Merged
merged 3 commits into from
Apr 3, 2018

Conversation

BraslavskiyAndrey
Copy link
Contributor

No description provided.

result = bidRequest.toBuilder()
.device(populatedDevice != null ? populatedDevice : bidRequest.getDevice())
.site(populatedSite != null ? populatedSite : bidRequest.getSite())
.user(populatedUser != null ? populatedUser : bidRequest.getUser())
// set the auction type to 1 if it wasn't on the request,
// since header bidding is generally a first-price auction.
.at(at == null || at == 0 ? 1 : at)
Copy link
Contributor

Choose a reason for hiding this comment

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


if (populatedDevice != null || populatedSite != null || populatedUser != null) {
if (populatedDevice != null || populatedSite != null || populatedUser != null || at == null || at == 0) {
Copy link
Contributor

Choose a reason for hiding this comment

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

at == null || at == 0 condition appears twice in this method and could be extracted to a variable

@Test
public void shouldNotSetAtIfItIsNotEqualsToNull(){
// given
givenBidRequest(BidRequest.builder()
Copy link
Contributor

Choose a reason for hiding this comment

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

This could be a one-liner

@schernysh schernysh merged commit 3a15800 into master Apr 3, 2018
@schernysh schernysh deleted the set-first-price-auction-default branch April 3, 2018 14:09
v-dridger added a commit to v-dridger/prebid-server-java that referenced this pull request Mar 16, 2023
VeryExtraordinaryUsername added a commit that referenced this pull request Dec 11, 2023
VeryExtraordinaryUsername added a commit that referenced this pull request Dec 12, 2023
muuki88 added a commit to highfivve/prebid-server-java that referenced this pull request Jan 22, 2024
VeryExtraordinaryUsername added a commit that referenced this pull request Jan 29, 2024
VeryExtraordinaryUsername added a commit that referenced this pull request Feb 26, 2024
VeryExtraordinaryUsername added a commit that referenced this pull request Feb 26, 2024
muuki88 added a commit to highfivve/prebid-server-java that referenced this pull request Mar 9, 2024
muuki88 added a commit to highfivve/prebid-server-java that referenced this pull request Mar 9, 2024
muuki88 added a commit to highfivve/prebid-server-java that referenced this pull request Mar 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants