mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-12 10:14:10 +01:00
Unlock Safari extension with Apple Watch for MacBook users in clamshell mode
Signed-off-by: Mikaël Barbero <mikael.barbero@eclipse-foundation.org>
This commit is contained in:
parent
117e789775
commit
5ed4e3e3f4
@ -152,7 +152,11 @@ func handleBiometricUnlock(_ message: [String: Any]?, _ context: NSExtensionCont
|
||||
var error: NSError?
|
||||
let laContext = LAContext()
|
||||
|
||||
laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: &error)
|
||||
if #available(macOSApplicationExtension 10.15, *) {
|
||||
laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometricsOrWatch, error: &error)
|
||||
} else {
|
||||
laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: &error)
|
||||
}
|
||||
|
||||
if let e = error, e.code != kLAErrorBiometryLockout {
|
||||
response.userInfo = notSupportedResponse
|
||||
|
Loading…
Reference in New Issue
Block a user