Skip to content

Commit

Permalink
Merge pull request #573 from adjust/v4334
Browse files Browse the repository at this point in the history
Version 4.33.4
  • Loading branch information
shashanksu authored Apr 26, 2023
2 parents 43b88df + 6d82408 commit f720f67
Show file tree
Hide file tree
Showing 19 changed files with 55 additions and 21 deletions.
2 changes: 1 addition & 1 deletion Adjust/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ext {
coreMinSdkVersion = 9
coreCompileSdkVersion = 33
coreTargetSdkVersion = 33
coreVersionName = '4.33.3'
coreVersionName = '4.33.4'
defaultVersionCode = 1
webbridgeMinSdkVersion = 17
samsungReferrerMinSdkVersion = 18
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-core/src/main/java/com/adjust/sdk/Adjust.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ private Adjust() {
*/
public static synchronized AdjustInstance getDefaultInstance() {
@SuppressWarnings("unused")
String VERSION = "!SDK-VERSION-STRING!:com.adjust.sdk:adjust-android:4.33.3";
String VERSION = "!SDK-VERSION-STRING!:com.adjust.sdk:adjust-android:4.33.4";

if (defaultInstance == null) {
defaultInstance = new AdjustInstance();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public interface Constants {

String SCHEME = "https";
String AUTHORITY = "app.adjust.com";
String CLIENT_SDK = "android4.33.3";
String CLIENT_SDK = "android4.33.4";
String LOGTAG = "Adjust";
String REFTAG = "reftag";
String INSTALL_REFERRER = "install_referrer";
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-criteo/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-imei/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class TelephonyIdsUtil {
private static String meids = null;
private static String deviceIds = null;

private static boolean allIdsAlreadyReadOnce = false;

static void injectImei(Map<String, String> parameters, Context context, ILogger logger) {
if (!AdjustImei.isImeiToBeRead) {
return;
Expand All @@ -32,13 +34,19 @@ static void injectImei(Map<String, String> parameters, Context context, ILogger
PackageBuilder.addString(parameters, "imeis", getImeis(telephonyManager, logger));
PackageBuilder.addString(parameters, "meids", getMeids(telephonyManager, logger));
PackageBuilder.addString(parameters, "device_ids", getDeviceIds(telephonyManager, logger));

allIdsAlreadyReadOnce = true;
}

private static String getDeviceIds(TelephonyManager telephonyManager, ILogger logger) {
if (deviceIds != null) {
return deviceIds;
}

if (allIdsAlreadyReadOnce) {
return null;
}

List<String> telephonyIdList = new ArrayList<String>();
for (int i = 0; i < 10; i++) {
String telephonyId = getDeviceIdByIndex(telephonyManager, i, logger);
Expand All @@ -56,6 +64,10 @@ private static String getDefaultDeviceId(TelephonyManager telephonyManager, ILog
return deviceId;
}

if (allIdsAlreadyReadOnce) {
return null;
}

try {
deviceId = telephonyManager.getDeviceId();
return deviceId;
Expand All @@ -81,6 +93,10 @@ private static String getImeis(TelephonyManager telephonyManager, ILogger logger
return imeis;
}

if (allIdsAlreadyReadOnce) {
return null;
}

List<String> imeiList = new ArrayList<String>();
for (int i = 0; i < 10; i++) {
String imei = getImeiByIndex(telephonyManager, i, logger);
Expand All @@ -97,6 +113,10 @@ private static String getDefaultImei(TelephonyManager telephonyManager, ILogger
return imei;
}

if (allIdsAlreadyReadOnce) {
return null;
}

try {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
imei = telephonyManager.getImei();
Expand Down Expand Up @@ -124,6 +144,10 @@ public static String getMeids(TelephonyManager telephonyManager, ILogger logger)
return meids;
}

if (allIdsAlreadyReadOnce) {
return null;
}

List<String> meidList = new ArrayList<String>();
for (int i = 0; i < 10; i++) {
String meid = getMeidByIndex(telephonyManager, i, logger);
Expand All @@ -140,6 +164,10 @@ private static String getDefaultMeid(TelephonyManager telephonyManager, ILogger
return meid;
}

if (allIdsAlreadyReadOnce) {
return null;
}

try {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
meid = telephonyManager.getMeid();
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-oaid/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
implementation 'com.huawei.hms:ads-identifier:3.4.56.300'
}

Expand Down
5 changes: 2 additions & 3 deletions Adjust/sdk-plugin-samsung-referrer/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,13 @@ android {
}

dependencies {
// compileOnly files('libs/galaxyapps_sdk_referrer-release-v2.0.aar')

// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'

// Add Samsung referrer lib via Maven.
implementation 'store.galaxy.samsung.installreferrer:samsung_galaxystore_install_referrer:3.0.1'
}

// read local properties
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import android.content.Context;

import com.adjust.sdk.ILogger;
import com.sec.android.app.samsungapps.installreferrer.api.InstallReferrerClient;
import com.sec.android.app.samsungapps.installreferrer.api.InstallReferrerStateListener;
import com.sec.android.app.samsungapps.installreferrer.api.ReferrerDetails;
import com.samsung.android.sdk.sinstallreferrer.api.InstallReferrerClient;
import com.samsung.android.sdk.sinstallreferrer.api.InstallReferrerStateListener;
import com.samsung.android.sdk.sinstallreferrer.api.ReferrerDetails;

import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public synchronized static ReferrerDetails getSamsungInstallReferrerDetails(Cont
return null;
}

com.sec.android.app.samsungapps.installreferrer.api.ReferrerDetails referrerDetails =
com.samsung.android.sdk.sinstallreferrer.api.ReferrerDetails referrerDetails =
SamsungReferrerClient.getReferrer(context, logger, 3000);
if (referrerDetails == null) {
return null;
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-sociomantic/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-trademob/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-vivo-referrer/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-webbridge/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'
}

// read local properties
Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-webbridge/src/main/assets/adjust.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ var Adjust = {
if (this.adjustConfig) {
return this.adjustConfig.getSdkPrefix();
} else {
return 'web-bridge4.33.3';
return 'web-bridge4.33.4';
}
},

Expand Down
2 changes: 1 addition & 1 deletion Adjust/sdk-plugin-xiaomi-referrer/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ dependencies {
// Add SDK via module.
compileOnly project(':sdk-core')
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.33.3'
// implementation 'com.adjust.sdk:adjust-android:4.33.4'

// Add xiaomi referrer lib via Maven.
implementation 'com.miui.referrer:homereferrer:1.0.0.6'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public TestActivityPackage(ActivityPackage activityPackage) {
// default values
appToken = "123456789012";
environment = "sandbox";
clientSdk = "android4.33.3";
clientSdk = "android4.33.4";
suffix = "";
attribution = new AdjustAttribution();
playServices = true;
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
### Version 4.33.4 (27th April 2023)
#### Changed
- Updated Samsung Install Referrer library version to 3.0.1.
- Updated IMEI reading attempt to only once.

---

### Version 4.33.3 (16th February 2023)
#### Fixed
- Added catching of exceptions in referrer plugins when thrown anytime while retrieving referrer.
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.33.3
4.33.4

0 comments on commit f720f67

Please sign in to comment.