package com.oblador.keychain;

import android.os.Build;
import android.content.Context;
import android.app.KeyguardManager;
import android.hardware.fingerprint.FingerprintManager;

public class DeviceAvailability {
    public static boolean isFingerprintAuthAvailable(Context context) {
        FingerprintManager fingerprintManager =
                (FingerprintManager) context.getSystemService(Context.FINGERPRINT_SERVICE);

        return android.os.Build.VERSION.SDK_INT >= 23 &&
            fingerprintManager.isHardwareDetected() &&
            fingerprintManager.hasEnrolledFingerprints();
    }

    public static boolean isSecure(Context context) {
        KeyguardManager keyguardManager =
                (KeyguardManager) context.getSystemService(Context.KEYGUARD_SERVICE);
        return android.os.Build.VERSION.SDK_INT >= 23 && keyguardManager.isDeviceSecure();
    }
}

@@ -272,32 +272,90 @@
 text context) %7B%0A
+        if (android.os.Build.VERSION.SDK_INT %3E= 23) %7B%0A    
         Fingerpr
@@ -478,17 +478,20 @@
 RVICE);%0A
-%0A
+    
         
@@ -501,62 +501,8 @@
 urn 
-android.os.Build.VERSION.SDK_INT %3E= 23 &&%0A            
 fing
@@ -540,16 +540,20 @@
 ed() &&%0A
+    
         
@@ -598,24 +598,56 @@
 erprints();%0A
+        %7D%0A        return false;%0A
     %7D%0A%0A    p

Update DeviceAvailability to work with Android < 6 (#109)