mirror of
https://github.com/SimpleMobileTools/Simple-Calendar.git
synced 2025-02-19 21:20:43 +01:00
avoid updating Types db table if it was just created
This commit is contained in:
parent
ab8cbf7726
commit
d343e8211f
@ -160,11 +160,11 @@ class DBHelper private constructor(val context: Context) : SQLiteOpenHelper(cont
|
||||
db.execSQL("ALTER TABLE $MAIN_TABLE_NAME ADD COLUMN $COL_EVENT_SOURCE TEXT DEFAULT ''")
|
||||
}
|
||||
|
||||
if (oldVersion < 16) {
|
||||
if (oldVersion in 7..15) {
|
||||
db.execSQL("ALTER TABLE $TYPES_TABLE_NAME ADD COLUMN $COL_TYPE_CALDAV_CALENDAR_ID INTEGER NOT NULL DEFAULT 0")
|
||||
}
|
||||
|
||||
if (oldVersion < 17) {
|
||||
if (oldVersion in 7..17) {
|
||||
db.execSQL("ALTER TABLE $TYPES_TABLE_NAME ADD COLUMN $COL_TYPE_CALDAV_DISPLAY_NAME TEXT DEFAULT ''")
|
||||
db.execSQL("ALTER TABLE $TYPES_TABLE_NAME ADD COLUMN $COL_TYPE_CALDAV_EMAIL TEXT DEFAULT ''")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user