applidium/ADClusterMapView — pull request #21 by scheinem (2013-04-23 11:55:02+00:00)
Title: Fixed potential crash in mapView's animationDidStop:finished:context:

In this method there was the following lines of code:

```objective-c
for (ADClusterAnnotation * annotation in self.annotations) {
if (![annotation isKindOfClass:[MKUserLocation class]]) {
if (annotation.shouldBeRemovedAfterAnimation) {
[annotation reset];
}
annotation.shouldBeRemovedAfterAnimation = NO;
}
}
```

But sometimes self.annotations contains objects of class "MKTeleportingUserLocation" (which is only a child of NSObject and not of MKUserLocation) and so on. So I changed this if from blacklist- to whitelist-method:

```objective-c
for (ADClusterAnnotation * annotation in self.annotations) {
if ([annotation isKindOfClass:[ADClusterAnnotation class]]) {
if (annotation.shouldBeRemovedAfterAnimation) {
[annotation reset];
}
annotation.shouldBeRemovedAfterAnimation = NO;
}
}
```