From f8162dc08f2c95377b36baf27472873c685cc433 Mon Sep 17 00:00:00 2001 From: Jenna Antilla <46546946+jennantilla@users.noreply.github.com> Date: Fri, 3 Nov 2023 15:15:55 -0700 Subject: [PATCH 1/2] Update version for v5.0.4 release --- Examples/OneSignalDemo/app/build.gradle | 4 ++-- .../core/src/main/java/com/onesignal/common/OneSignalUtils.kt | 2 +- OneSignalSDK/settings.gradle | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/OneSignalDemo/app/build.gradle b/Examples/OneSignalDemo/app/build.gradle index 9bce633c06..3a2476127d 100644 --- a/Examples/OneSignalDemo/app/build.gradle +++ b/Examples/OneSignalDemo/app/build.gradle @@ -84,12 +84,12 @@ dependencies { implementation 'com.github.bumptech.glide:glide:4.12.0' /** START - Google Play Builds **/ - gmsImplementation('com.onesignal:OneSignal:5.0.3') + gmsImplementation('com.onesignal:OneSignal:5.0.4') /** END - Google Play Builds **/ /** START - Huawei Builds **/ // Omit Google / Firebase libraries for Huawei builds. - huaweiImplementation('com.onesignal:OneSignal:5.0.3') { + huaweiImplementation('com.onesignal:OneSignal:5.0.4') { exclude group: 'com.google.android.gms', module: 'play-services-gcm' exclude group: 'com.google.android.gms', module: 'play-services-analytics' exclude group: 'com.google.android.gms', module: 'play-services-location' diff --git a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/OneSignalUtils.kt b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/OneSignalUtils.kt index b87b3a885f..43b6f092b7 100644 --- a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/OneSignalUtils.kt +++ b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/OneSignalUtils.kt @@ -6,7 +6,7 @@ object OneSignalUtils { /** * The version of this SDK. */ - const val SDK_VERSION: String = "050003" + const val SDK_VERSION: String = "050004" fun isValidEmail(email: String): Boolean { if (email.isEmpty()) { diff --git a/OneSignalSDK/settings.gradle b/OneSignalSDK/settings.gradle index e42b5bfefa..c5565ff4e9 100644 --- a/OneSignalSDK/settings.gradle +++ b/OneSignalSDK/settings.gradle @@ -3,7 +3,7 @@ gradle.rootProject { allprojects { group = 'com.onesignal' - version = '5.0.3' + version = '5.0.4' configurations.all { resolutionStrategy.dependencySubstitution { substitute(module('com.onesignal:OneSignal')).using(project(':OneSignal')) From 3f00ac1cafe429874f4fd6592ca0e57df5d71fe5 Mon Sep 17 00:00:00 2001 From: Jenna Antilla <46546946+jennantilla@users.noreply.github.com> Date: Fri, 3 Nov 2023 15:26:00 -0700 Subject: [PATCH 2/2] Update formatting to pass lint test --- .../com/onesignal/common/threading/ThreadUtils.kt | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/threading/ThreadUtils.kt b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/threading/ThreadUtils.kt index 639ec36def..1a6b4ff48c 100644 --- a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/threading/ThreadUtils.kt +++ b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/threading/ThreadUtils.kt @@ -48,8 +48,7 @@ fun suspendifyOnMain(block: suspend () -> Unit) { block() } } - } - catch (e: Exception) { + } catch (e: Exception) { Logging.error("Exception on thread with switch to main", e) } } @@ -70,8 +69,7 @@ fun suspendifyOnThread( runBlocking { block() } - } - catch (e: Exception) { + } catch (e: Exception) { Logging.error("Exception on thread", e) } } @@ -93,9 +91,8 @@ fun suspendifyOnThread( runBlocking { block() } - } - catch (e: Exception) { - Logging.error("Exception on thread '${name}'", e) + } catch (e: Exception) { + Logging.error("Exception on thread '$name'", e) } } }