Do not get setting if targetUserId == UserHandle.USER_NULL

Fixes: 135061626

Test: Builds
Change-Id: Ib5b667d1de0c112d198db853ed0767fc08e00fbf
This commit is contained in:
Kevin Chyn
2019-06-12 12:52:16 -07:00
parent 01462c0b95
commit 16cac92f01

View File

@@ -18,10 +18,15 @@ package com.android.server.biometrics;
import android.content.Context;
import android.os.Build;
import android.os.UserHandle;
import android.provider.Settings;
public class Utils {
public static boolean isDebugEnabled(Context context, int targetUserId) {
if (targetUserId == UserHandle.USER_NULL) {
return false;
}
if (!(Build.IS_ENG || Build.IS_USERDEBUG)) {
return false;
}