We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6785cff commit 102d527Copy full SHA for 102d527
src/modules/location/locationManager.ts
@@ -22,12 +22,10 @@ const MapboxLocationManager: typeof NativeRNMBXLocationModule = Platform.select(
22
const IsTurbo: boolean =
23
typeof MapboxLocationManager.onLocationUpdate === 'function';
24
25
-export const LocationModuleEventEmitter = Platform.select({
26
- ios: new NativeEventEmitter(MapboxLocationManager as any),
27
- android: !IsTurbo
+export const LocationModuleEventEmitter =
+ Platform.OS === 'ios' || (Platform.OS === 'android' && !IsTurbo)
28
? new NativeEventEmitter(MapboxLocationManager as any)
29
- : null,
30
-});
+ : null;
31
32
/**
33
* Location sent by locationManager
0 commit comments