Skip to content

Commit

Permalink
chore: minor improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
Desu Sai Venkat committed Oct 4, 2023
1 parent c6a4c89 commit 294f4ab
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Sources/Classes/RSDBPersistentManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -111,12 +111,11 @@ - (BOOL) isSQLCipherAvailable {
[database finalize:stmt];
}
[self closeDB];
[RSUtils removeFile:SQLCIPHER_TEST_DB_NAME];
}
@catch (NSException *exception) {
[RSLogger logError:[NSString stringWithFormat:@"RSDBPersistentManager: isSQLCipherAvailable: Failed to check if SQLCipher is available, reason: %@", exception.reason]];
[RSUtils removeFile:SQLCIPHER_TEST_DB_NAME];
[RSLogger logError:[NSString stringWithFormat:@"RSDBPersistentManager: isSQLCipherAvailable: Failed to check if SQLCipher is available, reason: %@", exception.reason]];
}
[RSUtils removeFile:SQLCIPHER_TEST_DB_NAME];
return isSQLCipherAvailable;
}

Expand Down Expand Up @@ -222,7 +221,7 @@ - (void)handleWhenUnencryptedDBExists:(RSDBEncryption * _Nullable)dbEncryption i
// delete unencrypted database; then create new encrypted database
// all previous events will be deleted
[RSLogger logError:[NSString stringWithFormat:@"RSDBPersistentManager: createDB: Failed to encrypt the existing unecnrypted db, creating a new encrypted db, error code: %d", code]];
// desu [self deleteUnEncryptedAndOpenEncryptedDB:dbEncryption];
[self deleteUnEncryptedAndOpenEncryptedDB:dbEncryption];
}
} else {
// open unencrypted database
Expand Down

0 comments on commit 294f4ab

Please sign in to comment.