forked from EVOgeek/Vmeda.Online
MOBILE-3633 calendar: Fix calendar DB migration
parent
1800beed31
commit
16e8b13083
|
@ -211,6 +211,7 @@ export const CALENDAR_SITE_SCHEMA: CoreSiteSchema = {
|
||||||
oldTable = 'addon_calendar_events';
|
oldTable = 'addon_calendar_events';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
await db.tableExists(oldTable);
|
await db.tableExists(oldTable);
|
||||||
|
|
||||||
// Move the records from the old table.
|
// Move the records from the old table.
|
||||||
|
@ -219,7 +220,6 @@ export const CALENDAR_SITE_SCHEMA: CoreSiteSchema = {
|
||||||
|
|
||||||
await Promise.all(promises);
|
await Promise.all(promises);
|
||||||
|
|
||||||
try {
|
|
||||||
db.dropTable(oldTable);
|
db.dropTable(oldTable);
|
||||||
} catch {
|
} catch {
|
||||||
// Old table does not exist, ignore.
|
// Old table does not exist, ignore.
|
||||||
|
|
Loading…
Reference in New Issue