Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 98127fb8 authored by Winson Chung's avatar Winson Chung
Browse files

Adding null check for focused stack before trying to switch affiliated tasks.

Bug: 19870065
Change-Id: I674914b9d4a63cb9c73fa71bbc4b82c210e2001f
parent 8d09a744
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -377,7 +377,7 @@ public class Recents extends SystemUI
        }

        // Return early if there are no tasks in the focused stack
        if (focusedStack.getTaskCount() == 0) return;
        if (focusedStack == null || focusedStack.getTaskCount() == 0) return;

        ActivityManager.RunningTaskInfo runningTask = mSystemServicesProxy.getTopMostTask();
        // Return early if there is no running task (can't determine affiliated tasks in this case)