mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
fix: remove foreign constraint on stack.primaryAssetId (#20052)
* fix: remove foreign constraint in stack.primaryAssetId * fix migration --------- Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
5fc4393e7a
commit
1dc62fce5f
8 changed files with 5521 additions and 126 deletions
|
|
@ -5,6 +5,7 @@ import 'package:drift/drift.dart';
|
|||
import 'package:drift/internal/migrations.dart';
|
||||
import 'schema_v1.dart' as v1;
|
||||
import 'schema_v2.dart' as v2;
|
||||
import 'schema_v3.dart' as v3;
|
||||
|
||||
class GeneratedHelper implements SchemaInstantiationHelper {
|
||||
@override
|
||||
|
|
@ -14,10 +15,12 @@ class GeneratedHelper implements SchemaInstantiationHelper {
|
|||
return v1.DatabaseAtV1(db);
|
||||
case 2:
|
||||
return v2.DatabaseAtV2(db);
|
||||
case 3:
|
||||
return v3.DatabaseAtV3(db);
|
||||
default:
|
||||
throw MissingSchemaException(version, versions);
|
||||
}
|
||||
}
|
||||
|
||||
static const versions = const [1, 2];
|
||||
static const versions = const [1, 2, 3];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue