Key backup: Check backup update on the homeserver

when opening the home or the settings screen in order to display the right banner and settings.
This commit is contained in:
manuroe
2019-02-06 17:34:16 +01:00
parent 10d792dd3e
commit 7c370e5feb
2 changed files with 6 additions and 0 deletions

View File

@@ -68,6 +68,9 @@ final class SettingsKeyBackupViewModel: SettingsKeyBackupViewModelType {
private func checkKeyBackupState() {
// Check homeserver update in background
self.keyBackup.forceRefresh(nil, failure: nil)
if let keyBackupVersion = self.keyBackup.keyBackupVersion {
self.keyBackup.trust(for: keyBackupVersion, onComplete: { [weak self] (keyBackupVersionTrust) in