Add check for the device having "feature face" before requesting the service

Personally, I think it'd be better for the service to return null rather
than throwing an error if it doesn't exisit but according to b/ throwing
is WAI.

Test: try running any test that might use ExandableNotificationRow on a
      device without face service and see that an exception isn't thrown
Bug: 135475155
Change-Id: I6cf7f3d39f411dc88d5fd75da0adb2c612acf880
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBypassController.kt b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBypassController.kt
index 58d1462..3f1cb6c 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBypassController.kt
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBypassController.kt
@@ -17,6 +17,7 @@
 package com.android.systemui.statusbar.phone
 
 import android.content.Context
+import android.content.pm.PackageManager
 import android.hardware.biometrics.BiometricSourceType
 import android.hardware.face.FaceManager
 import android.provider.Settings
@@ -73,6 +74,9 @@
                 }
             }
         })
+        if (!context.getPackageManager().hasSystemFeature(PackageManager.FEATURE_FACE)) {
+            return
+        }
         val faceManager = context.getSystemService(FaceManager::class.java)
         if (faceManager?.isHardwareDetected != true) {
             return