Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,7 @@ private static BidderBid mapToBidderBid(HbResponseSpace hbResponseSpace, HbRespo
.price(new BigDecimal(hbResponseAd.getPrice()))
.adm(hbResponseAd.getAdM())
.crid(hbResponseAd.getCrId())
.adomain(Collections.singletonList(hbResponseAd.getAdom()))
.w(hbResponseAd.getWidth())
.h(hbResponseAd.getHeight())
.build(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ public class HbResponseAd {
@JsonProperty("crid")
String crId;

@JsonProperty()
Copy link
Collaborator

Choose a reason for hiding this comment

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

please remove json property

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 know this field isn't needed, but all the other fields have it, and when I edit the adapter, I try to keep things consistent.

Copy link
Collaborator

@AntoxaAntoxic AntoxaAntoxic Oct 7, 2025

Choose a reason for hiding this comment

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

The best practice here is not leaving a code that does nothing. Anyway all other fields have the @JsonProperty because they need them (maybe except for adM - I believe it's just a typo, so you can rename it to adm and remove the annotation as well)

String adom;

@JsonProperty("w")
Integer width;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -615,6 +615,7 @@ public void makeBidsShouldReturnBannerBidWithExpectedFields() throws JsonProcess
.price("3.3")
.adM("some-adm")
.crId("CR-ID")
.adom("test.com")
.width(500)
.height(300)
.build()))))));
Expand All @@ -632,6 +633,7 @@ public void makeBidsShouldReturnBannerBidWithExpectedFields() throws JsonProcess
.price(BigDecimal.valueOf(3.3))
.adm("some-adm")
.crid("CR-ID")
.adomain(List.of("test.com"))
.w(500)
.h(300)
.build();
Expand All @@ -653,6 +655,7 @@ public void makeBidsShouldReturnBannerBidIfMissingAdunitCode() throws JsonProces
.price("3.3")
.adM("some-adm")
.crId("CR-ID")
.adom("test.com")
.width(1)
.height(1)
.build()))))));
Expand All @@ -671,6 +674,7 @@ public void makeBidsShouldReturnBannerBidIfMissingAdunitCode() throws JsonProces
.price(BigDecimal.valueOf(3.3))
.adm("some-adm")
.crid("CR-ID")
.adomain(List.of("test.com"))
.w(1)
.h(1)
.build();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
"adm": "<div>test</div>",
"adid": "imp_id",
"crid": "crid",
"adomain": [
"test.com"
],
"w": 600,
"h": 300,
"ext": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
"adm": "<div>test</div>",
"crid": "crid",
"id": "imp_id",
"adom": "test.com",
"w": 600,
"h": 300
}
]
}
]
}
}
Loading