chore(persistence): update schema version
Signed-off-by: xsahil03x <[email protected]>
This commit is contained in:
@@ -53,10 +53,13 @@ class MoorChatDatabase extends _$MoorChatDatabase {
|
||||
|
||||
// you should bump this number whenever you change or add a table definition.
|
||||
@override
|
||||
int get schemaVersion => 5;
|
||||
int get schemaVersion => 6;
|
||||
|
||||
@override
|
||||
MigrationStrategy get migration => MigrationStrategy(
|
||||
beforeOpen: (details) async {
|
||||
await customStatement('PRAGMA foreign_keys = ON;');
|
||||
},
|
||||
onUpgrade: (openingDetails, before, after) async {
|
||||
if (before != after) {
|
||||
final m = createMigrator();
|
||||
@@ -66,9 +69,6 @@ class MoorChatDatabase extends _$MoorChatDatabase {
|
||||
}
|
||||
}
|
||||
},
|
||||
beforeOpen: (details) async {
|
||||
await customStatement('PRAGMA foreign_keys = ON;');
|
||||
},
|
||||
);
|
||||
|
||||
/// Deletes all the tables
|
||||
|
||||
Reference in New Issue
Block a user