@@ -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