mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 11:18:21 +00:00
Fix NPE where CellLayout is null when removing item out of folder
Fix: 282249989 Test: create a folder of 2 app icons, remove one icon out of folder, no crash Change-Id: I3c132ec8833c7cb14066cc403c0641d089bab8ab
This commit is contained in:
@@ -94,6 +94,9 @@ public class LauncherDelegate {
|
||||
// folder
|
||||
CellLayout cellLayout = mLauncher.getCellLayout(info.container,
|
||||
info.screenId);
|
||||
if (cellLayout == null) {
|
||||
return;
|
||||
}
|
||||
finalItem = info.contents.remove(0);
|
||||
newIcon = mLauncher.createShortcut(cellLayout, finalItem);
|
||||
mLauncher.getModelWriter().addOrMoveItemInDatabase(finalItem,
|
||||
|
||||
Reference in New Issue
Block a user