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

Commit 20ec7596 authored by Jeff DeCew's avatar Jeff DeCew Committed by Android (Google) Code Review
Browse files

Merge "Ensure a publicVersion with MessagingStyle can inherit the...

Merge "Ensure a publicVersion with MessagingStyle can inherit the conversationType of the private version." into main
parents f0e8cc6f 6e6d893e
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -6942,6 +6942,12 @@ public class Notification implements Parcelable
        public RemoteViews makePublicContentView(boolean isLowPriority) {
            if (mN.publicVersion != null) {
                final Builder builder = recoverBuilder(mContext, mN.publicVersion);
                // copy non-sensitive style fields to the public style
                if (mStyle instanceof Notification.MessagingStyle privateStyle) {
                    if (builder.mStyle instanceof Notification.MessagingStyle publicStyle) {
                        publicStyle.mConversationType = privateStyle.mConversationType;
                    }
                }
                return builder.createContentView();
            }
            Bundle savedBundle = mN.extras;