From 15782dcb168ec03e3f8a0d6826abbd3b05400790 Mon Sep 17 00:00:00 2001 From: Tibor Kaputa Date: Thu, 24 Nov 2022 16:09:39 +0100 Subject: [PATCH] minor code update --- .../simplemobiletools/camera/helpers/MediaActionSound.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/camera/helpers/MediaActionSound.kt b/app/src/main/kotlin/com/simplemobiletools/camera/helpers/MediaActionSound.kt index a94f9412..79357deb 100644 --- a/app/src/main/kotlin/com/simplemobiletools/camera/helpers/MediaActionSound.kt +++ b/app/src/main/kotlin/com/simplemobiletools/camera/helpers/MediaActionSound.kt @@ -66,7 +66,7 @@ class MediaActionSound(private val context: Context) { if (status != 0) { sound.state = STATE_NOT_LOADED sound.id = 0 - Log.e(TAG, "OnLoadCompleteListener() error: $status loading sound: ${sound.name}") + Log.e(TAG, "OnLoadCompleteListener() error: $status loading sound: ${sound.name}") return@OnLoadCompleteListener } when (sound.state) { @@ -75,7 +75,7 @@ class MediaActionSound(private val context: Context) { soundToBePlayed = sound sound.state = STATE_LOADED } - else -> Log.e(TAG, "OnLoadCompleteListener() called in wrong state: ${sound.state} for sound: ${sound.name}") + else -> Log.e(TAG, "OnLoadCompleteListener() called in wrong state: ${sound.state} for sound: ${sound.name}") } } if (soundToBePlayed != null) { @@ -172,7 +172,7 @@ class MediaActionSound(private val context: Context) { sound.id = 0 } } - soundPool!!.release() + soundPool?.release() soundPool = null } removeHandlerCallbacks()