build

fun build(locations: List<LocationMarker>, merchants: List<ActivePerksMerchant>, filter: MerchantFilter = MerchantFilter()): List<MerchantPin>

Builds the pins a map draws, joining each location to a merchant and applying filter the same way ActivePerksCatalog.filter applies it to the merchant list, so a map and a list built from the same data always agree.

A location whose merchantId is absent from merchants - a stale id against a newer catalogue - falls through to brand matching rather than dropping the pin.