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

Commit 61abf214 authored by Beth Thibodeau's avatar Beth Thibodeau Committed by Android (Google) Code Review
Browse files

Merge "Revert logic to unregister callback in the background thread" into main

parents 4341d205 ce6d2e8f
Loading
Loading
Loading
Loading
+8 −9
Original line number Diff line number Diff line
@@ -382,16 +382,15 @@ public class NotificationMediaManager implements Dumpable {

    private void clearCurrentMediaNotificationSession() {
        mMediaMetadata = null;
        mBackgroundExecutor.execute(() -> {
        if (mMediaController != null) {
            if (DEBUG_MEDIA) {
                Log.v(TAG, "DEBUG_MEDIA: Disconnecting from old controller: "
                        + mMediaController.getPackageName());
            }
            // TODO(b/336612071): move to background thread
            mMediaController.unregisterCallback(mMediaListener);
                mMediaController = null;
        }
        });
        mMediaController = null;
    }

    public interface MediaListener {