### Refactored

- `ModuleTargetFilter`, which was responsible for checking if a file is a target file, has been ported to a serviceFeature.
  - And also tests have been added. The middleware-style-power.
- `ModuleObsidianAPI` has been removed and implemented in `APIService` and `RemoteService`.
- Now `APIService` is responsible for the network-online-status, not `databaseService.managers.networkManager`.
This commit is contained in:
vorotamoroz
2026-02-25 09:38:31 +00:00
parent be1642f1c1
commit 19c03ec8d8
14 changed files with 92 additions and 546 deletions

View File

@@ -262,9 +262,7 @@ export class ModuleMigration extends AbstractModule {
// Check local database for compromised chunks
const localCompromised = await countCompromisedChunks(this.localDatabase.localDatabase);
const remote = this.services.replicator.getActiveReplicator();
const remoteCompromised = this.core.managers.networkManager.isOnline
? await remote?.countCompromisedChunks()
: 0;
const remoteCompromised = this.services.API.isOnline ? await remote?.countCompromisedChunks() : 0;
if (localCompromised === false) {
Logger(`Failed to count compromised chunks in local database`, LOG_LEVEL_NOTICE);
return false;