|
@@ -419,14 +419,14 @@
|
|
|
|
|
|
+ (BOOL)isEndToEndEnabled:(NSString *)account
|
|
+ (BOOL)isEndToEndEnabled:(NSString *)account
|
|
{
|
|
{
|
|
- tableCapabilities *capabilities = [[NCManageDatabase sharedInstance] getCapabilitesWithAccount:account];
|
|
|
|
-
|
|
|
|
|
|
+ BOOL isE2EEEnabled = [[NCManageDatabase sharedInstance] getCapabilitiesE2EEEnabledWithAccount:account];
|
|
|
|
+
|
|
NSString *publicKey = [self getEndToEndPublicKey:account];
|
|
NSString *publicKey = [self getEndToEndPublicKey:account];
|
|
NSString *privateKey = [self getEndToEndPrivateKey:account];
|
|
NSString *privateKey = [self getEndToEndPrivateKey:account];
|
|
NSString *passphrase = [self getEndToEndPassphrase:account];
|
|
NSString *passphrase = [self getEndToEndPassphrase:account];
|
|
NSString *publicKeyServer = [self getEndToEndPublicKeyServer:account];
|
|
NSString *publicKeyServer = [self getEndToEndPublicKeyServer:account];
|
|
|
|
|
|
- if (passphrase.length > 0 && privateKey.length > 0 && publicKey.length > 0 && publicKeyServer.length > 0 && capabilities.endToEndEncryption) {
|
|
|
|
|
|
+ if (passphrase.length > 0 && privateKey.length > 0 && publicKey.length > 0 && publicKeyServer.length > 0 && isE2EEEnabled) {
|
|
|
|
|
|
return YES;
|
|
return YES;
|
|
|
|
|