KeyHandler: Simplify boolean check

getBooleanExtra() does not return `Boolean?` anymore, or ever?

Change-Id: I8a1987ee1244148dccbf434d424ea1a60f7506cf
This commit is contained in:
LuK1337
2022-10-19 20:38:47 +02:00
parent 45b4b90881
commit 14a43e3d98

View File

@@ -44,7 +44,7 @@ class KeyHandler(context: Context) : DeviceKeyHandler {
override fun onReceive(context: Context, intent: Intent) {
val stream = intent.getIntExtra(AudioManager.EXTRA_VOLUME_STREAM_TYPE, -1)
val state = intent.getBooleanExtra(AudioManager.EXTRA_STREAM_VOLUME_MUTED, false)
if (stream == AudioSystem.STREAM_MUSIC && state == false) {
if (stream == AudioSystem.STREAM_MUSIC && !state) {
wasMuted = false
}
}