fixed unreachable code error

This commit is contained in:
Michael Starke
2017-11-28 15:49:43 +01:00
parent 6f72301dfd
commit d8351f12f2

View File

@@ -539,10 +539,10 @@ typedef void (^MPPasswordChangedBlock)(BOOL didChangePassword);
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.5 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.5 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[self editPasswordWithCompetionHandler:^(NSInteger result) { [self editPasswordWithCompetionHandler:^(NSInteger result) {
/* if password was changed, reset change key and dismiss */ /* if password was changed, reset change key and dismiss */
if(NSModalResponseOK == result) { if(result == NSModalResponseOK) {
document.tree.metaData.enforceMasterKeyChangeOnce = NO; document.tree.metaData.enforceMasterKeyChangeOnce = NO;
} }
else if(NSModalResponseCancel) { else if(result == NSModalResponseCancel) {
/* password was not changes, so keep nagging the user! */ /* password was not changes, so keep nagging the user! */
[self _presentPasswordIntervalAlerts]; [self _presentPasswordIntervalAlerts];
} }