Skip to content

Instantly share code, notes, and snippets.

View chriswunsch00's full-sized avatar
😏

Chris Wunsch chriswunsch00

😏
View GitHub Profile
private func loadPins() {
var lamps = viewModel.batchLamps(forRect: mapView.visibleMapRect)
if lamps.count == 0 {
mapView.removeAnnotations(mapView.annotations)
return
} else if lamps.count > 100 {
let range = 100...lamps.count - 1
lamps.removeSubrange(range)
}