release 2.9.6.1 : fix crashes with internal database error

This commit is contained in:
Geno 2021-02-01 09:41:50 +01:00
parent e101bd8ba2
commit 696f791dca
3 changed files with 5 additions and 4 deletions

View File

@ -95,8 +95,8 @@ android {
defaultConfig {
minSdkVersion 21
targetSdkVersion 29
versionCode 407
versionName "2.9.6"
versionCode 408
versionName "2.9.6.1"
archivesBaseName += "-$versionName"
applicationId "eu.sum7.conversations"
resValue "string", "applicationId", applicationId

View File

@ -0,0 +1 @@
• fix crashes (error on internal database migration)

View File

@ -62,7 +62,7 @@ import eu.siacs.conversations.xmpp.mam.MamReference;
public class DatabaseBackend extends SQLiteOpenHelper {
private static final String DATABASE_NAME = "history";
private static final int DATABASE_VERSION = 48;
private static final int DATABASE_VERSION = 49;
private static DatabaseBackend instance = null;
private static final String CREATE_CONTATCS_STATEMENT = "create table "
+ Contact.TABLENAME + "(" + Contact.ACCOUNT + " TEXT, "
@ -563,7 +563,7 @@ public class DatabaseBackend extends SQLiteOpenHelper {
if (oldVersion < 48 && newVersion >= 48) {
db.execSQL("ALTER TABLE " + Contact.TABLENAME + " ADD COLUMN " + Contact.PRESENCE_NAME + " TEXT");
}
if (oldVersion < 48 && newVersion >= 48) {
if (oldVersion < 49 && newVersion >= 49) {
db.execSQL("ALTER TABLE " + Contact.TABLENAME + " ADD COLUMN " + Contact.RTP_CAPABILITY + " TEXT");
}
}