recreate the context

This commit is contained in:
Iurii 2019-01-21 05:44:07 +03:00
parent fb86b0ffe9
commit a4ff6a667a
1 changed files with 4 additions and 5 deletions

View File

@ -75,7 +75,8 @@ public final class BiometricsService {
/** /**
Initiates system biometrics authentication process. Initiates system biometrics authentication process.
Once evaluated, will return success until the context is deallocated or invalidated. Once evaluated, will return success until the context is deallocated.
Call "clear" to use a new context instance.
- parameters: - parameters:
- description: prompt on the system alert - description: prompt on the system alert
@ -97,10 +98,8 @@ public final class BiometricsService {
} }
} }
/// This method allows invalidating the context manually while it is in scope. /// Replace old instance of the context with the new one
/// Invalidation terminates any existing policy evaluation and the respective call will public func clear() {
/// fail with LAErrorAppCancel.
public func invalidate() {
laContext = LAContext() laContext = LAContext()
} }