Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AND-209] Update stream-android-push to v1.3.0. #1290

Merged
merged 4 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,10 @@ object StreamVideoInitHelper {
ensureSingleInstance = false,
notificationConfig = NotificationConfig(
pushDeviceGenerators = listOf(
FirebasePushDeviceGenerator(providerName = "firebase"),
FirebasePushDeviceGenerator(
context = context,
providerName = "firebase",
),
),
),
tokenProvider = object : TokenProvider {
Expand Down
4 changes: 2 additions & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ itu = "1.7.3"
streamWebRTC = "1.3.6"
streamNoiseCancellation = "1.0.2"
streamResult = "1.3.0"
streamChat = "6.9.0"
streamChat = "6.10.0"
streamLog = "1.3.1"
streamPush = "1.1.8"
streamPush = "1.3.0"

androidxTest = "1.5.2"
androidxTestCore = "1.5.0"
Expand Down
2 changes: 1 addition & 1 deletion stream-video-android-core/consumer-proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -67,5 +67,5 @@
# Prevent R8 from stripping notification-handling classes.
-keep class io.getstream.video.android.core.notifications.internal.VideoPushDelegate { *; }
-keep class io.getstream.android.push.delegate.PushDelegate { *; }
-keep class io.getstream.android.push.delegate.PushDelegateProvider { *; }
-keep class io.getstream.android.push.delegate.AndroidPushDelegateProvider { *; }
-keep class io.getstream.android.push.permissions.PushPermissionsInitializer { *; }
2 changes: 1 addition & 1 deletion stream-video-android-core/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@

<application>
<provider
android:name="io.getstream.android.push.delegate.PushDelegateProvider"
android:name="io.getstream.android.push.delegate.AndroidPushDelegateProvider"
android:authorities="${applicationId}.io.getstream.android.push"
android:exported="false"
tools:node="merge">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ internal class StreamNotificationManager private constructor(
logger.d { "[registerPushDevice] no args" }
// first get a push device generator that works for this device
notificationConfig.pushDeviceGenerators
.firstOrNull { it.isValidForThisDevice(context) }
.firstOrNull { it.isValidForThisDevice() }
?.let { generator ->
generator.onPushDeviceGeneratorSelected()
generator.asyncGeneratePushDevice { generatedDevice ->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@

package io.getstream.video.android.core.notifications.internal

import android.content.Context
import io.getstream.android.push.PushDevice
import io.getstream.android.push.delegate.AndroidPushDelegateProvider
import io.getstream.android.push.delegate.PushDelegate
import io.getstream.android.push.delegate.PushDelegateProvider
import io.getstream.log.taggedLogger
import io.getstream.video.android.core.StreamVideo
import io.getstream.video.android.core.dispatchers.DispatcherProvider
Expand All @@ -31,11 +30,9 @@ import kotlinx.coroutines.launch
/**
* Class used to handle Push Notifications.
*
* It is used by reflection by [PushDelegateProvider] class.
* It is used by reflection by [AndroidPushDelegateProvider] class.
*/
internal class VideoPushDelegate(
context: Context,
) : PushDelegate(context) {
internal class VideoPushDelegate : PushDelegate() {
private val logger by taggedLogger("Call:PushDelegate")
private val DEFAULT_CALL_TEXT = "Unknown caller"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ class RingingApp : Application() {
// Make sure that the provider name is equal to the "Name" of the configuration in Stream Dashboard.
pushDeviceGenerators = listOf(
FirebasePushDeviceGenerator(
context = context,
providerName = "firebase",
),
),
Expand Down
Loading