From f8f07a02bb1a5c975e1b72e69cd05d5e3c7aedb9 Mon Sep 17 00:00:00 2001 From: kieran Date: Thu, 26 Dec 2024 14:35:30 +0000 Subject: [PATCH] chore: bump pkgs --- packages/system-react/package.json | 4 ++-- packages/system/package.json | 2 +- packages/system/src/nostr.ts | 2 +- packages/system/src/note-collection.ts | 4 ++-- packages/wallet/package.json | 4 ++-- packages/worker-relay/package.json | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/packages/system-react/package.json b/packages/system-react/package.json index 40d826ce5..e34569543 100644 --- a/packages/system-react/package.json +++ b/packages/system-react/package.json @@ -1,6 +1,6 @@ { "name": "@snort/system-react", - "version": "1.6.0", + "version": "1.6.1", "description": "React hooks for @snort/system", "main": "dist/index.js", "module": "src/index.ts", @@ -17,7 +17,7 @@ ], "dependencies": { "@snort/shared": "^1.0.17", - "@snort/system": "^1.6.0", + "@snort/system": "^1.6.1", "react": "^18.2.0" }, "devDependencies": { diff --git a/packages/system/package.json b/packages/system/package.json index 47a185c85..31f4c3dde 100644 --- a/packages/system/package.json +++ b/packages/system/package.json @@ -1,6 +1,6 @@ { "name": "@snort/system", - "version": "1.6.0", + "version": "1.6.1", "description": "Snort nostr system package", "type": "module", "main": "dist/index.js", diff --git a/packages/system/src/nostr.ts b/packages/system/src/nostr.ts index c88ea8943..21e4d6b58 100644 --- a/packages/system/src/nostr.ts +++ b/packages/system/src/nostr.ts @@ -14,7 +14,7 @@ export interface TaggedNostrEvent extends NostrEvent { /** * A list of relays this event was seen on */ - relays: Array; + relays?: Array; /** * Additional context diff --git a/packages/system/src/note-collection.ts b/packages/system/src/note-collection.ts index 077cd8f2b..af1e29fe1 100644 --- a/packages/system/src/note-collection.ts +++ b/packages/system/src/note-collection.ts @@ -1,4 +1,4 @@ -import { SortedMap, dedupe } from "@snort/shared"; +import { SortedMap, appendDedupe, dedupe } from "@snort/shared"; import { EventExt, EventType, TaggedNostrEvent } from "."; import { findTag } from "./utils"; import { EventEmitter } from "eventemitter3"; @@ -72,7 +72,7 @@ export class KeyedReplaceableNoteStore extends HookedNoteStore { const existing = this.#events.get(keyOnEvent); if (a.created_at > (existing?.created_at ?? 0)) { if (existing) { - a.relays = dedupe([...(existing.relays ?? []), ...a.relays]); + a.relays = appendDedupe(existing.relays, a.relays); } this.#events.set(keyOnEvent, a); changes.push(a); diff --git a/packages/wallet/package.json b/packages/wallet/package.json index e529d1912..e695eb6a3 100644 --- a/packages/wallet/package.json +++ b/packages/wallet/package.json @@ -1,6 +1,6 @@ { "name": "@snort/wallet", - "version": "0.2.3", + "version": "0.2.4", "description": "Snort wallet system package", "type": "module", "main": "dist/index.js", @@ -23,7 +23,7 @@ "@lightninglabs/lnc-web": "^0.3.1-alpha", "@scure/base": "^1.1.6", "@snort/shared": "^1.0.17", - "@snort/system": "^1.6.0", + "@snort/system": "^1.6.1", "debug": "^4.3.4", "eventemitter3": "^5.0.1" }, diff --git a/packages/worker-relay/package.json b/packages/worker-relay/package.json index c1e61d265..238c23918 100644 --- a/packages/worker-relay/package.json +++ b/packages/worker-relay/package.json @@ -1,6 +1,6 @@ { "name": "@snort/worker-relay", - "version": "1.3.0", + "version": "1.3.1", "description": "A nostr relay in a service worker", "main": "dist/index.js", "types": "dist/index.d.ts",