From a3a00b8456a4cd525e01f1ea0ead3537729023f1 Mon Sep 17 00:00:00 2001 From: Gigi Date: Sat, 18 Oct 2025 00:43:18 +0200 Subject: [PATCH] debug: add setName distribution logging for kind:30001 bookmarks Added console log to show the distribution of setName values for all kind:30001 bookmarks. This will help diagnose why 489 Amethyst bookmarks aren't appearing in the amethystPublic/amethystPrivate groups. Expected to see setName='bookmark' but need to verify what values are actually present in the data. --- src/utils/bookmarkUtils.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/utils/bookmarkUtils.tsx b/src/utils/bookmarkUtils.tsx index c4276d4c..3ea41e53 100644 --- a/src/utils/bookmarkUtils.tsx +++ b/src/utils/bookmarkUtils.tsx @@ -110,6 +110,15 @@ export function groupIndividualBookmarks(items: IndividualBookmark[]) { })) console.log('[bookmark] 📊 Sample items:', samples) + // Debug: Show setName distribution for kind:30001 + const kind30001Items = sorted.filter(i => i.sourceKind === 30001) + const setNameCounts = new Map() + kind30001Items.forEach(i => { + const count = setNameCounts.get(i.setName) || 0 + setNameCounts.set(i.setName, count + 1) + }) + console.log('[bookmark] 📊 kind:30001 setName distribution:', Object.fromEntries(setNameCounts)) + // Group by source list, not by content type const nip51Public = sorted.filter(i => i.sourceKind === 10003 && !i.isPrivate) const nip51Private = sorted.filter(i => i.sourceKind === 10003 && i.isPrivate)