From b5e1acf4e308a5f6d859a6634399d40f1a9fbbe3 Mon Sep 17 00:00:00 2001 From: Ladd Date: Thu, 2 Jan 2025 21:26:13 -0600 Subject: [PATCH] minor stuff --- src/collection-abstract.ts | 3 +-- src/delta.ts | 2 +- src/lossy.ts | 1 + 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/collection-abstract.ts b/src/collection-abstract.ts index 5b0ed28..69565a5 100644 --- a/src/collection-abstract.ts +++ b/src/collection-abstract.ts @@ -20,7 +20,7 @@ export abstract class Collection { abstract initializeView(): void; - abstract resolve(id: string): ResolvedViewOne | undefined; + abstract resolve(id: DomainEntityID): ResolvedViewOne | undefined; rhizomeConnect(rhizomeNode: RhizomeNode) { this.rhizomeNode = rhizomeNode; @@ -36,7 +36,6 @@ export abstract class Collection { this.eventStream.emit("update", res); }); - // TODO: Fix this rhizomeNode.httpServer.httpApi.serveCollection(this); debug(`[${this.rhizomeNode.config.peerId}]`, `Connected ${this.name} to rhizome`); diff --git a/src/delta.ts b/src/delta.ts index 9b1683a..37166ab 100644 --- a/src/delta.ts +++ b/src/delta.ts @@ -17,7 +17,7 @@ type PointerV1 = { export type Scalar = string | number | null; export type Reference = { - [key: PropertyID]: DomainEntityID + [key: DomainEntityID]: PropertyID }; export type PointersV2 = { diff --git a/src/lossy.ts b/src/lossy.ts index d6776b6..bc27186 100644 --- a/src/lossy.ts +++ b/src/lossy.ts @@ -23,6 +23,7 @@ export abstract class Lossy { this.lossless.eventStream.on("updated", (id, deltaIds) => { debug(`[${this.lossless.rhizomeNode.config.peerId}] entity ${id} updated, deltaIds:`, JSON.stringify(deltaIds)); + this.ingestUpdate(id, deltaIds); }); }