react-native-maps 1.29.2 → 1.29.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -157,7 +157,10 @@ const NSInteger AIRMapMaxZoomLevel = 20;
157
157
  [self insertReactSubview:(UIView *)childSubviews[i] atIndex:atIndex];
158
158
  }
159
159
  }
160
- [_reactSubviews insertObject:(UIView *)subview atIndex:(NSUInteger) atIndex];
160
+ if (subview != nil) {
161
+ NSUInteger safeIndex = MIN((NSUInteger)atIndex, _reactSubviews.count);
162
+ [_reactSubviews insertObject:(UIView *)subview atIndex:safeIndex];
163
+ }
161
164
  }
162
165
  #pragma clang diagnostic pop
163
166
 
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "types": "dist/src/index.d.ts",
8
8
  "author": "Leland Richardson <leland.m.richardson@gmail.com>",
9
9
  "homepage": "https://github.com/react-native-maps/react-native-maps#readme",
10
- "version": "1.29.2",
10
+ "version": "1.29.3",
11
11
  "license": "MIT",
12
12
  "scripts": {
13
13
  "lint": "eslint . --max-warnings 0",