Snap for 8654853 from 824cdb5e38987f62da962fbe95e623457ee41520 to t-keystone-qcom-release

Change-Id: I59515218fdd299e00ea20a8c5662f8e4c2ce0f05
diff --git a/service/java/com/android/server/uwb/UwbSessionManager.java b/service/java/com/android/server/uwb/UwbSessionManager.java
index 29a79fb..76bae00 100644
--- a/service/java/com/android/server/uwb/UwbSessionManager.java
+++ b/service/java/com/android/server/uwb/UwbSessionManager.java
@@ -766,27 +766,26 @@
                                         }
                                     }
                                 }
-                            }
-                            if (status != UwbUciConstants.STATUS_CODE_OK) {
+                                if (status != UwbUciConstants.STATUS_CODE_OK) {
+                                    if (rangingReconfigureParams.getAction()
+                                            == MULTICAST_LIST_UPDATE_ACTION_ADD) {
+                                        mSessionNotificationManager.onControleeAddFailed(
+                                                uwbSession, status);
+                                    } else if (rangingReconfigureParams.getAction()
+                                            == MULTICAST_LIST_UPDATE_ACTION_DELETE) {
+                                        mSessionNotificationManager.onControleeRemoveFailed(
+                                                uwbSession, status);
+                                    }
+                                    return status;
+                                }
                                 if (rangingReconfigureParams.getAction()
                                         == MULTICAST_LIST_UPDATE_ACTION_ADD) {
-                                    mSessionNotificationManager.onControleeAddFailed(
-                                            uwbSession, status);
+                                    mSessionNotificationManager.onControleeAdded(uwbSession);
                                 } else if (rangingReconfigureParams.getAction()
                                         == MULTICAST_LIST_UPDATE_ACTION_DELETE) {
-                                    mSessionNotificationManager.onControleeRemoveFailed(
-                                            uwbSession, status);
+                                    mSessionNotificationManager.onControleeRemoved(uwbSession);
                                 }
-                                return status;
                             }
-                            if (rangingReconfigureParams.getAction()
-                                    == MULTICAST_LIST_UPDATE_ACTION_ADD) {
-                                mSessionNotificationManager.onControleeAdded(uwbSession);
-                            } else if (rangingReconfigureParams.getAction()
-                                    == MULTICAST_LIST_UPDATE_ACTION_DELETE) {
-                                mSessionNotificationManager.onControleeRemoved(uwbSession);
-                            }
-
                             status = mConfigurationManager.setAppConfigurations(
                                     uwbSession.getSessionId(), param);
                             Log.d(TAG, "status: " + status);