mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-28 03:46:00 +01:00
Small improvements
This commit is contained in:
@@ -483,7 +483,8 @@ public abstract class DB extends RoomDatabase {
|
||||
if (cache_size != null) {
|
||||
cache_size = -cache_size; // kibibytes
|
||||
Log.i("Set PRAGMA cache_size=" + cache_size);
|
||||
try (Cursor cursor = db.query(new SimpleSQLiteQuery("PRAGMA cache_size=" + cache_size + ";"))) {
|
||||
// TODO CASA
|
||||
try (Cursor cursor = db.query("PRAGMA cache_size=" + cache_size + ";")) {
|
||||
cursor.moveToNext(); // required
|
||||
}
|
||||
}
|
||||
@@ -503,7 +504,8 @@ public abstract class DB extends RoomDatabase {
|
||||
// https://www.sqlite.org/pragma.html
|
||||
for (String pragma : DB_PRAGMAS)
|
||||
if (!"compile_options".equals(pragma) || BuildConfig.DEBUG) {
|
||||
try (Cursor cursor = db.query(new SimpleSQLiteQuery("PRAGMA " + pragma + ";"))) {
|
||||
// TODO CASA
|
||||
try (Cursor cursor = db.query("PRAGMA " + pragma + ";")) {
|
||||
boolean has = false;
|
||||
while (cursor.moveToNext()) {
|
||||
has = true;
|
||||
|
||||
Reference in New Issue
Block a user