chore(android): add null checks (#4168)

This commit is contained in:
Krzysztof Moch
2024-09-14 15:20:50 +02:00
committed by GitHub
parent 84a27f3d9f
commit b74cb59602
2 changed files with 14 additions and 6 deletions

View File

@@ -121,7 +121,7 @@ class VideoPlaybackService : MediaSessionService() {
}
private fun buildNotification(session: MediaSession): Notification {
val returnToPlayer = Intent(this, sourceActivity).apply {
val returnToPlayer = Intent(this, sourceActivity ?: this.javaClass).apply {
flags = Intent.FLAG_ACTIVITY_SINGLE_TOP or Intent.FLAG_ACTIVITY_CLEAR_TOP
}