Fix NPE am: a3e2e68fd0 am: 2f86e541d9

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17591433

Change-Id: I59bc04ac4963cfb95fc8bdf669759624e4aaf4f5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>