summaryrefslogtreecommitdiffstats
path: root/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java
diff options
context:
space:
mode:
Diffstat (limited to 'quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java')
-rw-r--r--quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java b/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java
index 8f1282ded..24fc61bef 100644
--- a/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java
+++ b/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionAppTracker.java
@@ -95,6 +95,10 @@ public class PredictionAppTracker extends AppLaunchTracker {
private AppPredictor createPredictor(Client client, int count) {
AppPredictionManager apm = mContext.getSystemService(AppPredictionManager.class);
+ if (apm == null) {
+ return null;
+ }
+
AppPredictor predictor = apm.createAppPredictionSession(
new AppPredictionContext.Builder(mContext)
.setUiSurface(client.id)