RoomVC: Remove the beta warning modal when opening an e2e room

#2239
This commit is contained in:
manuroe
2019-02-12 19:24:08 +01:00
parent 893ac32167
commit 8523426a56
2 changed files with 1 additions and 29 deletions
-29
View File
@@ -567,35 +567,6 @@
}
}];
[self refreshMissedDiscussionsCount:YES];
// Warn about the beta state of e2e encryption when entering the first time in an encrypted room
MXKAccount *account = [[MXKAccountManager sharedManager] accountForUserId:self.roomDataSource.mxSession.myUser.userId];
if (account && !account.isWarnedAboutEncryption && self.roomDataSource.room.summary.isEncrypted)
{
[currentAlert dismissViewControllerAnimated:NO completion:nil];
__weak __typeof(self) weakSelf = self;
currentAlert = [UIAlertController alertControllerWithTitle:NSLocalizedStringFromTable(@"warning", @"Vector", nil)
message:NSLocalizedStringFromTable(@"room_warning_about_encryption", @"Vector", nil)
preferredStyle:UIAlertControllerStyleAlert];
[currentAlert addAction:[UIAlertAction actionWithTitle:[NSBundle mxk_localizedStringForKey:@"ok"]
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
if (weakSelf)
{
typeof(self) self = weakSelf;
self->currentAlert = nil;
account.warnedAboutEncryption = YES;
}
}]];
[currentAlert mxk_setAccessibilityIdentifier:@"RoomVCEncryptionAlert"];
[self presentViewController:currentAlert animated:YES completion:nil];
}
}
- (void)viewDidDisappear:(BOOL)animated