Instance Method

renewCredentials(for:completion:)

Renews account credentials when the credentials are no longer valid.

Declaration

func renewCredentials(for account: ACAccount!, completion completionHandler: ACAccountStoreCredentialRenewalHandler!)

Parameters

account

The account to renew credentials.

completionHandler

The handler to call when the renewal has completed.

Discussion

For Twitter and Sina Weibo accounts, this method will prompt the user to go to Settings to re-enter their password.

For Facebook accounts, if the access token has become invalid due to a regular expiration, this method will obtain a new one.

If the user has deauthorized your app, this renewal request will return ACAccountCredentialRenewResultRejected.

See Also

Renewing Account Credentials

typealias ACAccountStoreCredentialRenewalHandler

Specifies a handler to call when credentials are renewed.

enum ACAccountCredentialRenewResult

Status codes of credential renewal requests.