mirror of
https://github.com/immich-app/immich
synced 2025-10-17 18:19:27 +00:00
fix: cleanup logger DB in isolates (#20730)
Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
68b617130a
commit
9c8c52874a
6 changed files with 25 additions and 28 deletions
|
|
@ -47,14 +47,11 @@ abstract final class Bootstrap {
|
|||
);
|
||||
}
|
||||
|
||||
static Future<void> initDomain(Isar db, {bool shouldBufferLogs = true}) async {
|
||||
// load drift dbs
|
||||
final loggerDb = DriftLogger();
|
||||
|
||||
static Future<void> initDomain(Isar db, DriftLogger logDb, {bool shouldBufferLogs = true}) async {
|
||||
await StoreService.init(storeRepository: IsarStoreRepository(db));
|
||||
|
||||
await LogService.init(
|
||||
logRepository: LogRepository(loggerDb),
|
||||
logRepository: LogRepository(logDb),
|
||||
storeRepository: IsarStoreRepository(db),
|
||||
shouldBuffer: shouldBufferLogs,
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue