Skip to content

Commit 5dca01b

Browse files
Check if clonedCells list is not empty
1 parent a6a73e8 commit 5dca01b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

base/src/main/java/com/smartdevicelink/managers/screen/menu/BaseMenuManager.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ public void setMenuCells(@NonNull List<MenuCell> cells){
176176
// We are in NONE or the menu is in use, bail out of here
177177
waitingOnHMIUpdate = true;
178178
waitingUpdateMenuCells = new ArrayList<>();
179-
if (clonedCells != null) {
179+
if (clonedCells != null && !clonedCells.isEmpty()) {
180180
waitingUpdateMenuCells.addAll(clonedCells);
181181
}
182182
return;
@@ -190,7 +190,7 @@ public void setMenuCells(@NonNull List<MenuCell> cells){
190190
}
191191
// copy new list
192192
menuCells = new ArrayList<>();
193-
if (clonedCells != null) {
193+
if (clonedCells != null && !clonedCells.isEmpty()) {
194194
menuCells.addAll(clonedCells);
195195
}
196196

0 commit comments

Comments
 (0)