authorize(localizedReason:completion:)
Performs an authorization on the right.
Declaration
func authorize(localizedReason: String, completion handler: @escaping @Sendable ((any Error)?) -> Void)func authorize(localizedReason: String) async throwsParameters
- localizedReason:
A reason for the authorization that the system displays to the user.
- handler:
A completion handler called at the end of the authorization process.
errorIf
nil, the authorization is successful. Otherwise, the error contains information about the failure reason.