Skip to content

Commit

Permalink
Merge pull request #6190 from Bnyro/master
Browse files Browse the repository at this point in the history
fix: crash when destroying activity after media session
  • Loading branch information
Bnyro authored Jun 30, 2024
2 parents 8780107 + 4834650 commit 2f1dea3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ class NowPlayingNotification(
* Destroy the [NowPlayingNotification]
*/
fun destroySelf() {
mediaSession.release()
if (this::mediaSession.isInitialized) mediaSession.release()

nManager.cancel(NotificationId.PLAYER_PLAYBACK.id)
}
Expand Down

0 comments on commit 2f1dea3

Please sign in to comment.