diff options
| author | 2020-12-14 18:34:52 +0000 | |
|---|---|---|
| committer | 2020-12-14 18:34:52 +0000 | |
| commit | 849332255e31ec12fb5c4455cb81c93d8ab8b149 (patch) | |
| tree | 4c8c4a4e1d7539ac993bac0a5f52b02a851c7cdd | |
| parent | 155e594fee10eb13eac255001c8521d9929b21c9 (diff) | |
| parent | 9d36cc2280289c570945cc6aa1df84f919df8a2d (diff) | |
Merge "Don't reset default launcher if the user is not loaded"
| -rw-r--r-- | services/core/java/com/android/server/pm/ShortcutService.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/pm/ShortcutService.java b/services/core/java/com/android/server/pm/ShortcutService.java index c68fe81d0565..56fb5e8fd449 100644 --- a/services/core/java/com/android/server/pm/ShortcutService.java +++ b/services/core/java/com/android/server/pm/ShortcutService.java @@ -537,7 +537,9 @@ public class ShortcutService extends IShortcutService.Stub { synchronized (mLock) { // Clear the launcher cache for this user. It will be set again next time the default // launcher is read from RoleManager. - getUserShortcutsLocked(userId).setCachedLauncher(null); + if (isUserLoadedLocked(userId)) { + getUserShortcutsLocked(userId).setCachedLauncher(null); + } } } |