From 889755396b620c0d6b593f0e2a450e0962db483a Mon Sep 17 00:00:00 2001 From: Tyler Rister Date: Fri, 11 Mar 2022 12:52:52 -0500 Subject: [PATCH 1/2] Updated appsflyer version and updated some method calls that changed --- appsflyer/build.gradle | 2 +- .../remotecommands/appsflyer/AppsFlyerInstance.kt | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/appsflyer/build.gradle b/appsflyer/build.gradle index 7f5738b..e3360e0 100644 --- a/appsflyer/build.gradle +++ b/appsflyer/build.gradle @@ -34,7 +34,7 @@ dependencies { implementation 'androidx.appcompat:appcompat:1.0.2' implementation 'androidx.core:core-ktx:1.0.2' api 'com.tealium:remotecommands:1.0.0' - implementation 'com.appsflyer:af-android-sdk:5.4.3' + implementation 'com.appsflyer:af-android-sdk:6.5.3' implementation 'com.android.installreferrer:installreferrer:1.1.2' testImplementation 'junit:junit:4.12' diff --git a/appsflyer/src/main/java/com/tealium/remotecommands/appsflyer/AppsFlyerInstance.kt b/appsflyer/src/main/java/com/tealium/remotecommands/appsflyer/AppsFlyerInstance.kt index ab98452..15b08a8 100644 --- a/appsflyer/src/main/java/com/tealium/remotecommands/appsflyer/AppsFlyerInstance.kt +++ b/appsflyer/src/main/java/com/tealium/remotecommands/appsflyer/AppsFlyerInstance.kt @@ -70,11 +70,11 @@ class AppsFlyerInstance( } override fun trackLocation(latitude: Double, longitude: Double) { - AppsFlyerLib.getInstance().trackLocation(application, latitude, longitude) + AppsFlyerLib.getInstance().logLocation(application, latitude, longitude) } override fun trackEvent(eventType: String, eventParameters: Map?) { - AppsFlyerLib.getInstance().trackEvent(application, eventType, eventParameters) + AppsFlyerLib.getInstance().logEvent(application, eventType, eventParameters) } override fun setHost(host: String, hostPrefix: String?) { @@ -95,7 +95,7 @@ class AppsFlyerInstance( } override fun disableDeviceTracking(disable: Boolean) { - AppsFlyerLib.getInstance().setDeviceTrackingDisabled(disable) + AppsFlyerLib.getInstance().anonymizeUser(disable) } override fun resolveDeepLinkUrls(links: List) { @@ -104,7 +104,7 @@ class AppsFlyerInstance( } override fun stopTracking(isTrackingStopped: Boolean) { - AppsFlyerLib.getInstance().stopTracking(isTrackingStopped, application.applicationContext) + AppsFlyerLib.getInstance().stop(isTrackingStopped, application.applicationContext) } fun setMinsBetweenSessions(seconds: Int) { @@ -112,7 +112,7 @@ class AppsFlyerInstance( } fun anonymizeUser(isDisabled: Boolean) { - AppsFlyerLib.getInstance().setDeviceTrackingDisabled(isDisabled) + AppsFlyerLib.getInstance().anonymizeUser(isDisabled) } fun addCustomData(data: HashMap) { @@ -146,7 +146,7 @@ class AppsFlyerInstance( application.applicationContext ) AppsFlyerLib.getInstance() - .startTracking(weakActivity?.get() ?: application.applicationContext) + .start(weakActivity?.get() ?: application.applicationContext) } private fun getApplication() { From 3c30201f2bab1504f1fe676bc38ca0c67b27f24a Mon Sep 17 00:00:00 2001 From: Tyler Rister Date: Fri, 11 Mar 2022 12:54:42 -0500 Subject: [PATCH 2/2] Bumped version number of remote command lib --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 4c738db..4877437 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ buildscript { ext.kotlin_version = '1.4.10' ext.mockk_version = '1.9' - ext.tealium_appsflyer_version = '1.1.0' + ext.tealium_appsflyer_version = '1.2.0' repositories { google()