Skip to content

Commit b6f65b8

Browse files
committed
Small fixes
1 parent 25494f6 commit b6f65b8

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

android/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,6 @@ dependencies {
7373
api "com.appsflyer:af-android-sdk:${safeExtGet('appsflyerVersion', '6.15.2')}"
7474
implementation "com.android.installreferrer:installreferrer:${safeExtGet('installReferrerVersion', '2.2')}"
7575
if (includeConnector){
76-
implementation 'com.appsflyer:purchase-connector:2.1.0'
76+
implementation 'com.appsflyer:purchase-connector:2.1.1'
7777
}
7878
}

android/src/main/includeConnector/com/appsflyer/reactnative/PCAppsFlyerModule.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public class PCAppsFlyerModule extends ReactContextBaseJavaModule {
2424

2525
//WeakReference prevents memory leaks by allowing the garbage collector to collect the ReactApplicationContext when it's no longer needed.
2626
private WeakReference<ReactApplicationContext> reactContext;
27-
private boolean isModuleEnabled;
27+
private boolean isPurchaseConnectorModuleEnabled;
2828
private ConnectorWrapper connectorWrapper;
2929
private String TAG = "AppsFlyer_" + PLUGIN_VERSION;
3030

@@ -34,8 +34,8 @@ public class PCAppsFlyerModule extends ReactContextBaseJavaModule {
3434
public PCAppsFlyerModule(ReactApplicationContext reactContext) {
3535
super(reactContext);
3636
this.reactContext = new WeakReference<>(reactContext);
37-
this.isModuleEnabled = BuildConfig.INCLUDE_CONNECTOR;
38-
Log.d("AppsFlyer_", "PurchaseConnector inclusion status: " + this.isModuleEnabled);
37+
this.isPurchaseConnectorModuleEnabled = BuildConfig.INCLUDE_CONNECTOR;
38+
Log.d("AppsFlyer_", "PurchaseConnector inclusion status: " + this.isPurchaseConnectorModuleEnabled);
3939
}
4040

4141
@Override
@@ -45,7 +45,7 @@ public String getName() {
4545

4646
@ReactMethod
4747
public void create(ReadableMap config) {
48-
if (!isModuleEnabled) {
48+
if (!isPurchaseConnectorModuleEnabled) {
4949
Log.e(TAG, "PurchaseConnector is not enabled. Please enable it in your build.gradle");
5050
return;
5151
}
@@ -98,7 +98,7 @@ public void create(ReadableMap config) {
9898

9999
@ReactMethod
100100
public void startObservingTransactions() {
101-
if (!isModuleEnabled || connectorWrapper == null) {
101+
if (!isPurchaseConnectorModuleEnabled || connectorWrapper == null) {
102102
Log.e(TAG, "PurchaseConnector is not enabled or not initialized");
103103
return;
104104
}
@@ -108,7 +108,7 @@ public void startObservingTransactions() {
108108

109109
@ReactMethod
110110
public void stopObservingTransactions() {
111-
if (!isModuleEnabled || connectorWrapper == null) {
111+
if (!isPurchaseConnectorModuleEnabled || connectorWrapper == null) {
112112
Log.e(TAG, "PurchaseConnector is not enabled or not initialized");
113113
return;
114114
}
@@ -118,7 +118,7 @@ public void stopObservingTransactions() {
118118

119119
@ReactMethod
120120
public void setSubscriptionPurchaseEventDataSource(ReadableMap dataSource) {
121-
if (!isModuleEnabled) {
121+
if (!isPurchaseConnectorModuleEnabled) {
122122
Log.e(TAG, "PurchaseConnector is not enabled");
123123
return;
124124
}
@@ -137,7 +137,7 @@ public void setSubscriptionPurchaseEventDataSource(ReadableMap dataSource) {
137137

138138
@ReactMethod
139139
public void setInAppPurchaseEventDataSource(ReadableMap dataSource) {
140-
if (!isModuleEnabled) {
140+
if (!isPurchaseConnectorModuleEnabled) {
141141
Log.e(TAG, "PurchaseConnector is not enabled");
142142
return;
143143
}

0 commit comments

Comments
 (0)