diff --git a/Resources/Apple/README.md b/Resources/Apple/README.md index ca804ef..c701d5a 100644 --- a/Resources/Apple/README.md +++ b/Resources/Apple/README.md @@ -30,11 +30,6 @@ let result = try await authenticator // get authentication status let status = authenticator.isAuthenticated -// check authentication status -// we should check this when we need to explicitly query authenticator to check if authenticated -let isAuthenticated = try await authenticator - .checkAuthentication() - // signOut user authenticator.signOut() // all provider data regarding the use auth is cleared at this point ``` diff --git a/Sources/Apple/AppleAuthenticator.swift b/Sources/Apple/AppleAuthenticator.swift index cb407a7..37901de 100644 --- a/Sources/Apple/AppleAuthenticator.swift +++ b/Sources/Apple/AppleAuthenticator.swift @@ -57,16 +57,6 @@ extension AppleAuthenticator: Authenticator { public var isAuthenticated: Authenticated { storage.string(forKey: storageUserIdKey) != nil && storage.bool(forKey: storageAuthenticatedKey) } - - /// Checks the current auth state and returns the boolean value asynchronously. - public func checkAuthentication() async -> Authenticated { - guard let userId = storage.string(forKey: storageUserIdKey) else { - return false - } - - let credentialState = try? await ASAuthorizationAppleIDProvider().credentialState(forUserID: userId) - return credentialState == .authorized - } /// Boolean if given `url` should be handled. ///