Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4329e7ce authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Catch BadParcelableException when checking extras" into main am: 55df1e26

parents 4b48614f 55df1e26
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ import android.content.Context
import android.graphics.drawable.Icon
import android.media.session.MediaController
import android.media.session.PlaybackState
import android.os.BadParcelableException
import android.util.Log
import com.android.systemui.Flags.mediaControlsPostsOptimization
import com.android.systemui.biometrics.Utils.toBitmap
@@ -109,9 +110,14 @@ private fun areCustomActionsEqual(
    }
    if (firstAction.extras != null) {
        firstAction.extras.keySet().forEach { key ->
            try {
                if (firstAction.extras[key] != secondAction.extras[key]) {
                    return false
                }
            } catch (e: BadParcelableException) {
                Log.e(TAG, "Cannot unparcel extras", e)
                return false
            }
        }
    }
    return true