Fix syncing when network latency is present #4

Merged
schmelczer merged 58 commits from asch/fixes into master 2025-03-16 20:13:50 +00:00
Showing only changes of commit c250e82998 - Show all commits

View file

@ -1,7 +1,8 @@
import type { DocumentMetadata, RelativePath } from "src/persistence/database";
import type { DocumentMetadata, RelativePath } from "../persistence/database";
import { EMPTY_HASH } from "./hash";
export function findMatchingFileBasedOnHash(
// TODO: make this smarter so that offline files can be renamed & edited at the same time
export function findMatchingFile(
contentHash: string,
candidates: [RelativePath, DocumentMetadata][]
): [RelativePath, DocumentMetadata] | undefined {