Store intermediate certificates

This commit is contained in:
M66B
2020-01-30 14:19:15 +01:00
parent ff08ec5667
commit 8fb2409e36
7 changed files with 2190 additions and 7 deletions

View File

@@ -60,7 +60,7 @@ import io.requery.android.database.sqlite.SQLiteDatabase;
// https://developer.android.com/topic/libraries/architecture/room.html
@Database(
version = 135,
version = 136,
entities = {
EntityIdentity.class,
EntityAccount.class,
@@ -1321,6 +1321,13 @@ public abstract class DB extends RoomDatabase {
db.execSQL("CREATE VIEW IF NOT EXISTS `identity_view` AS " + TupleIdentityView.query);
db.execSQL("CREATE VIEW IF NOT EXISTS `folder_view` AS " + TupleFolderView.query);
}
})
.addMigrations(new Migration(135, 136) {
@Override
public void migrate(@NonNull SupportSQLiteDatabase db) {
Log.i("DB migration from version " + startVersion + " to " + endVersion);
db.execSQL("ALTER TABLE `certificate` ADD COLUMN `intermediate` INTEGER NOT NULL DEFAULT 0");
}
});
}