Conversation
| throw new PreBidException("Missing mediaType for bid: " + bid.getId()); | ||
| } | ||
|
|
||
| if (markupType != 1) { |
There was a problem hiding this comment.
Can we enum the 1 as banner please :)
There was a problem hiding this comment.
BidType.banner enum value is 0. Initially I used:
return switch (markupType) {
case 1 -> BidType.banner;
default -> throw new PreBidException(
"Unable to fetch mediaType " + bid.getMtype() + " in multi-format: " + bid.getImpid());
};But enums with 1 value are not allowed.
I can either:
- create a variable
final int banner = 1;
if (markupType != banner) {
}- add a comment
There was a problem hiding this comment.
A comment will suffice as its a single test
| } | ||
|
|
||
| private static List<BidderBid> extractBids(BidResponse bidResponse) { | ||
| if (bidResponse == null || CollectionUtils.isEmpty(bidResponse.getSeatbid())) { |
There was a problem hiding this comment.
bidResponse.getSeatbid().isEmpty() ?
There was a problem hiding this comment.
As per contributing guidelines, I followed already existing adapters style, they all have this logic to check if it's empty
|
|
||
| private static List<BidderBid> extractBids(BidResponse bidResponse) { | ||
| if (bidResponse == null || CollectionUtils.isEmpty(bidResponse.getSeatbid())) { | ||
| return Collections.emptyList(); |
| } | ||
| } | ||
|
|
||
| private Boolean validCustomEndpointUrl(String customUrl) { |
There was a problem hiding this comment.
Agreed better to use primitive types
|
Repo is in the wrong place @mbonnafon |
Yes, I did that on purpose, to submit a clean PR |
71ccdef to
946d515
Compare
946d515 to
a376abd
Compare


🔧 Type of changes
✨ What's the context?
New bidder adapter for Mobkoi, port from PBS-Go.
Maintainer: platformteam@mobkoi.com
Related Changes:
🔎 New Bid Adapter Checklist
🧪 Test plan
How do you know the changes are safe to ship to production?
🏎 Quality check