react-native-radar 3.18.1-beta.1 → 3.18.1
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.
package/android/build.gradle
CHANGED
|
@@ -18,7 +18,7 @@ android {
|
|
|
18
18
|
minSdkVersion 16
|
|
19
19
|
targetSdkVersion 31
|
|
20
20
|
versionCode 1
|
|
21
|
-
versionName '3.18.1
|
|
21
|
+
versionName '3.18.1'
|
|
22
22
|
}
|
|
23
23
|
lintOptions {
|
|
24
24
|
abortOnError false
|
|
@@ -45,6 +45,6 @@ repositories {
|
|
|
45
45
|
|
|
46
46
|
dependencies {
|
|
47
47
|
api 'com.facebook.react:react-native:+'
|
|
48
|
-
api 'io.radar:sdk:3.18.
|
|
48
|
+
api 'io.radar:sdk:3.18.1'
|
|
49
49
|
}
|
|
50
50
|
|
|
@@ -96,7 +96,7 @@ public class RNRadarModule extends ReactContextBaseJavaModule implements Permiss
|
|
|
96
96
|
this.fraud = fraud;
|
|
97
97
|
SharedPreferences.Editor editor = getReactApplicationContext().getSharedPreferences("RadarSDK", Context.MODE_PRIVATE).edit();
|
|
98
98
|
editor.putString("x_platform_sdk_type", "ReactNative");
|
|
99
|
-
editor.putString("x_platform_sdk_version", "3.18.1
|
|
99
|
+
editor.putString("x_platform_sdk_version", "3.18.1");
|
|
100
100
|
editor.apply();
|
|
101
101
|
if (fraud) {
|
|
102
102
|
Radar.initialize(getReactApplicationContext(), publishableKey, receiver, Radar.RadarLocationServicesProvider.GOOGLE, fraud);
|
package/ios/Cartfile.resolved
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
github "radarlabs/radar-sdk-ios" "3.18.
|
|
1
|
+
github "radarlabs/radar-sdk-ios" "3.18.1"
|
package/ios/RNRadar.m
CHANGED
|
@@ -102,7 +102,7 @@ RCT_EXPORT_MODULE();
|
|
|
102
102
|
|
|
103
103
|
RCT_EXPORT_METHOD(initialize:(NSString *)publishableKey fraud:(BOOL)fraud) {
|
|
104
104
|
[[NSUserDefaults standardUserDefaults] setObject:@"ReactNative" forKey:@"radar-xPlatformSDKType"];
|
|
105
|
-
[[NSUserDefaults standardUserDefaults] setObject:@"3.18.1
|
|
105
|
+
[[NSUserDefaults standardUserDefaults] setObject:@"3.18.1" forKey:@"radar-xPlatformSDKVersion"];
|
|
106
106
|
[Radar initializeWithPublishableKey:publishableKey];
|
|
107
107
|
}
|
|
108
108
|
|
|
@@ -193,7 +193,7 @@ RCT_EXPORT_METHOD(requestPermissions:(BOOL)background resolve:(RCTPromiseResolve
|
|
|
193
193
|
|
|
194
194
|
CLAuthorizationStatus status = [CLLocationManager authorizationStatus];
|
|
195
195
|
if (background && status == kCLAuthorizationStatusAuthorizedWhenInUse) {
|
|
196
|
-
|
|
196
|
+
[locationManager requestAlwaysAuthorization];
|
|
197
197
|
} else if (status == kCLAuthorizationStatusNotDetermined) {
|
|
198
198
|
[locationManager requestWhenInUseAuthorization];
|
|
199
199
|
} else {
|
|
@@ -1152,9 +1152,9 @@ RCT_EXPORT_METHOD(logConversion:(NSDictionary *)optionsDict resolve:(RCTPromiseR
|
|
|
1152
1152
|
};
|
|
1153
1153
|
|
|
1154
1154
|
if (revenue) {
|
|
1155
|
-
[Radar logConversionWithName:name metadata:metadata completionHandler:completionHandler];
|
|
1156
|
-
} else {
|
|
1157
1155
|
[Radar logConversionWithName:name revenue:revenue metadata:metadata completionHandler:completionHandler];
|
|
1156
|
+
} else {
|
|
1157
|
+
[Radar logConversionWithName:name metadata:metadata completionHandler:completionHandler];
|
|
1158
1158
|
}
|
|
1159
1159
|
}
|
|
1160
1160
|
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "React Native module for Radar, the leading geofencing and location tracking platform",
|
|
4
4
|
"homepage": "https://radar.com",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
|
-
"version": "3.18.1
|
|
6
|
+
"version": "3.18.1",
|
|
7
7
|
"main": "dist/index.js",
|
|
8
8
|
"files": [
|
|
9
9
|
"/android",
|
|
@@ -51,7 +51,7 @@ const withRadarIOS = (config, args) => {
|
|
|
51
51
|
const filePath = path_1.default.join(config.modRequest.platformProjectRoot, 'Podfile');
|
|
52
52
|
const contents = await promises_1.default.readFile(filePath, 'utf-8');
|
|
53
53
|
// Check if the pod declaration already exists
|
|
54
|
-
if (contents.indexOf("pod 'RadarSDKMotion', '3.18.
|
|
54
|
+
if (contents.indexOf("pod 'RadarSDKMotion', '3.18.1'") === -1) {
|
|
55
55
|
// Find the target block
|
|
56
56
|
const targetRegex = /target '(\w+)' do/g;
|
|
57
57
|
const match = targetRegex.exec(contents);
|
|
@@ -60,7 +60,7 @@ const withRadarIOS = (config, args) => {
|
|
|
60
60
|
const targetEndIndex = contents.indexOf('end', targetStartIndex) + 3;
|
|
61
61
|
// Insert the pod declaration within the target block
|
|
62
62
|
const targetBlock = contents.substring(targetStartIndex, targetEndIndex);
|
|
63
|
-
const updatedTargetBlock = targetBlock.replace(/(target '(\w+)' do)/, `$1\n pod 'RadarSDKMotion', '3.18.
|
|
63
|
+
const updatedTargetBlock = targetBlock.replace(/(target '(\w+)' do)/, `$1\n pod 'RadarSDKMotion', '3.18.1'`);
|
|
64
64
|
const newContents = contents.replace(targetBlock, updatedTargetBlock);
|
|
65
65
|
// Write the updated contents back to the Podfile
|
|
66
66
|
await promises_1.default.writeFile(filePath, newContents);
|