Skip to main content

commit_credentials

Function commit_credentials 

Source
pub fn commit_credentials(
    keychain: &CredentialKeychains,
    credentials: &StorageCredentials,
    code: Option<(&RestoreCode, &SavedName)>,
) -> Result<CredentialRollback, SyncError>
Expand description

Commit device credentials and, on Apple, the separate S3 key. Setup and bootstrap also supply the restore code with the store’s name, and remove any S3 entry when setting up an account provider. Replacing credentials supplies no code; OAuth refresh touches neither person entry. A failed write restores every prior value and returns any rollback failures with the original cause.