Close database after fetching it

Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
Mario Danic 2018-01-15 07:17:34 +01:00
parent 41cd5a3fd6
commit a79a872e69
2 changed files with 2 additions and 1 deletions

View file

@ -92,7 +92,7 @@ dependencies {
implementation 'io.requery:requery:1.4.1'
implementation 'io.requery:requery-android:1.4.1'
implementation 'net.zetetic:android-database-sqlcipher:3.5.7'
implementation 'net.zetetic:android-database-sqlcipher:3.5.9'
annotationProcessor 'io.requery:requery-processor:1.4.1'
compile 'org.parceler:parceler-api:1.1.9'

View file

@ -105,6 +105,7 @@ public final class MainActivity extends AppCompatActivity implements ActionBarPr
}
if (!router.hasRootController() && hasDb && userUtils.anyUserExists()) {
sqlCipherDatabaseSource.close();
router.setRoot(RouterTransaction.with(new MagicBottomNavigationController())
.pushChangeHandler(new HorizontalChangeHandler())
.popChangeHandler(new HorizontalChangeHandler()));