Merge "Check null before getting DeviceProfile in AbsSwipeUpHandler" into tm-qpr-dev

This commit is contained in:
Alex Chau authored and Android (Google) Code Review committed 2022-06-24 10:05:27 +00:00
commit f7526085a9
1 file changed
+1 -1
@@ -1136,7 +1136,7 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
mInputConsumerProxy.enable();
}
if (endTarget == HOME) {
duration = mActivity.getDeviceProfile().isTaskbarPresent
duration = mActivity != null && mActivity.getDeviceProfile().isTaskbarPresent
? StaggeredWorkspaceAnim.DURATION_TASKBAR_MS
: StaggeredWorkspaceAnim.DURATION_MS;
// Early detach the nav bar once the endTarget is determined as HOME