Skip to content

Commit

Permalink
Release 17.7.4 (#1388)
Browse files Browse the repository at this point in the history
  • Loading branch information
jyaganeh authored Apr 5, 2024
1 parent 1805be9 commit 50d2a13
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 19 deletions.
11 changes: 6 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,27 @@

[Migration Guides](https://github.com/urbanairship/android-library/tree/main/documentation/migration)

## Version 17.7.4, March 27, 2024
Patch release that fixes channel ID creation delay after enabling a feature when none was enabled. The SDK will new create the channel ID without having to relaunch the app. Apps that have no features enabled at launch should update to this version or later.
## Version 17.7.4, April 5, 2024
Patch release that fixes a potential crash on Android 13 (API 33) channel ID creation delay after enabling a feature when none was enabled. The SDK will new create the channel ID without having to relaunch the app. Apps that have no features enabled at launch should update to this version or later.

### Changes
- Fixed channel ID creation delay after enabling a feature when none was enabled.
- Fixed a potential NPE when reading from intent extras on API 33.

## Version 17.7.3, Feb 16, 2024
## Version 17.7.3, February 16, 2024
Patch release that adjusts locale targeting behavior for In-App Automation and messaging. The SDK will now check the device's primary language against the target locale, instead of checking whether any user selected languages match the target locale.

### Changes
- Adjust locale targeting behavior to only consider the primary locale selection.

## Version 17.7.2, Jan 29, 2024
## Version 17.7.2, January 29, 2024
Patch release that fixes an issue with message limits not being respected in certain cases. Apps that make use of limits should update to this version or later.

### Changes
- Fixed message limits not being respected in certain cases.
- Improvements for images and GIFs in Surveys and Scenes.

## Version 16.11.2, Jan 29, 2024
## Version 16.11.2, January 29, 2024
Patch release that fixes an issue with message limits not being respected in certain cases. Apps on SDK v16 that make use of limits should update to this version or the latest 17.x release.

### Changes
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
android.useAndroidX=true
android.databinding.incremental=true
kapt.incremental.apt=true
org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+UseParallelGC
org.gradle.jvmargs=-Xmx2048m -XX:+UseParallelGC
org.gradle.caching=true
org.gradle.parallel=true
Original file line number Diff line number Diff line change
@@ -1,24 +1,17 @@
package com.urbanairship.debug.utils

import android.content.Intent
import android.os.Build
import android.os.Bundle
import android.os.Parcelable

internal inline fun <reified T : Parcelable> Bundle.getParcelableCompat(key: String): T? {
return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
// The new getParcelable API was added in API 33, but came with a bug that could lead to
// NPEs. This was fixed in API 34, but we still need to use the deprecated API for 33.
// see: https://issuetracker.google.com/issues/240585930
return if (Build.VERSION.SDK_INT > Build.VERSION_CODES.TIRAMISU) {
getParcelable(key, T::class.java)
} else {
@Suppress("DEPRECATION")
getParcelable(key) as? T
}
}

internal inline fun <reified T : Parcelable> Intent.getParcelableExtraCompat(key: String): T? {
return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
getParcelableExtra(key, T::class.java)
} else {
@Suppress("DEPRECATION")
getParcelableExtra(key) as? T
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import android.app.Activity
import android.os.Build

internal inline fun <reified T> Activity.parcelableExtra(key: String): T? = when {
Build.VERSION.SDK_INT >= 33 -> intent.getParcelableExtra(key, T::class.java)
// The new getParcelableExtra API was added in API 33, but came with a bug that could lead to
// NPEs. This was fixed in API 34, but we still need to use the deprecated API for 33.
// see: https://issuetracker.google.com/issues/240585930
Build.VERSION.SDK_INT > 33 -> intent.getParcelableExtra(key, T::class.java)
else -> @Suppress("DEPRECATION") intent.getParcelableExtra(key) as? T
}
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ public class LiveUpdateNotificationReceiver : BroadcastReceiver() {
}

private inline fun <reified T> Intent.getParcelableExtraCompat(key: String): T? = when {
Build.VERSION.SDK_INT >= 33 -> getParcelableExtra(key, T::class.java)
// The new getParcelableExtra API was added in API 33, but came with a bug that could lead to
// NPEs. This was fixed in API 34, but we still need to use the deprecated API for 33.
// see: https://issuetracker.google.com/issues/240585930
Build.VERSION.SDK_INT > 33 -> getParcelableExtra(key, T::class.java)
else -> @Suppress("DEPRECATION") getParcelableExtra(key) as? T
}

0 comments on commit 50d2a13

Please sign in to comment.