@ -71,7 +71,7 @@
@@ -71,7 +71,7 @@
// Handle real-time updates - process reactions when new ones arrive
async function handleReactionUpdate(updated: NostrEvent[]) {
console.lo g(`[FeedReactionButtons] Received reaction update for event ${ event . id . substring ( 0 , 16 )} ...:`, {
console.debu g(`[FeedReactionButtons] Received reaction update for event ${ event . id . substring ( 0 , 16 )} ...:`, {
count: updated.length,
events: updated.map(r => ({
id: r.id.substring(0, 16) + '...',
@ -103,8 +103,8 @@
@@ -103,8 +103,8 @@
// Use getProfileReadRelays() to include defaultRelays + profileRelays + user inbox + localRelays
// This ensures we get all reactions from the complete relay set, matching ThreadList behavior
const reactionRelays = relayManager.getProfileReadRelays();
console.lo g(`[FeedReactionButtons] Loading reactions for event ${ event . id . substring ( 0 , 16 )} ... (kind ${ event . kind } )`);
console.lo g(`[FeedReactionButtons] Using relays:`, reactionRelays);
console.debu g(`[FeedReactionButtons] Loading reactions for event ${ event . id . substring ( 0 , 16 )} ... (kind ${ event . kind } )`);
console.debu g(`[FeedReactionButtons] Using relays:`, reactionRelays);
// Clear and rebuild reactions map for this event
allReactionsMap.clear();
@ -120,7 +120,7 @@
@@ -120,7 +120,7 @@
{ useCache : true , cacheResults : true , onUpdate : handleReactionUpdate }
);
console.lo g(`[FeedReactionButtons] Reactions fetched:`, {
console.debu g(`[FeedReactionButtons] Reactions fetched:`, {
eventId: event.id.substring(0, 16) + '...',
kind: event.kind,
withLowerE: reactionsWithLowerE.length,
@ -150,7 +150,7 @@
@@ -150,7 +150,7 @@
}
const reactionEvents = Array.from(allReactionsMap.values());
console.lo g(`[FeedReactionButtons] All reactions (deduplicated):`, {
console.debu g(`[FeedReactionButtons] All reactions (deduplicated):`, {
total: reactionEvents.length,
events: reactionEvents.map(r => ({
id: r.id.substring(0, 16) + '...',
@ -164,7 +164,7 @@
@@ -164,7 +164,7 @@
// Filter out deleted reactions (kind 5)
const filteredReactions = await filterDeletedReactions(reactionEvents);
console.lo g(`[FeedReactionButtons] After filtering deleted reactions:`, {
console.debu g(`[FeedReactionButtons] After filtering deleted reactions:`, {
before: reactionEvents.length,
after: filteredReactions.length,
filtered: reactionEvents.length - filteredReactions.length,
@ -196,7 +196,7 @@
@@ -196,7 +196,7 @@
{ useCache : true }
);
console.lo g(`[FeedReactionButtons] Deletion events fetched:`, {
console.debu g(`[FeedReactionButtons] Deletion events fetched:`, {
count: deletionEvents.length,
events: deletionEvents.map(d => ({
id: d.id.substring(0, 16) + '...',
@ -221,7 +221,7 @@
@@ -221,7 +221,7 @@
}
}
console.lo g(`[FeedReactionButtons] Deleted reaction IDs by pubkey:`,
console.debu g(`[FeedReactionButtons] Deleted reaction IDs by pubkey:`,
Array.from(deletedReactionIdsByPubkey.entries()).map(([pubkey, ids]) => ({
pubkey: pubkey.substring(0, 16) + '...',
deletedIds: Array.from(ids).map(id => id.substring(0, 16) + '...')
@ -233,7 +233,7 @@
@@ -233,7 +233,7 @@
const deletedIds = deletedReactionIdsByPubkey.get(reaction.pubkey);
const isDeleted = deletedIds & & deletedIds.has(reaction.id);
if (isDeleted) {
console.lo g(`[FeedReactionButtons] Filtering out deleted reaction:`, {
console.debu g(`[FeedReactionButtons] Filtering out deleted reaction:`, {
id: reaction.id.substring(0, 16) + '...',
pubkey: reaction.pubkey.substring(0, 16) + '...',
content: reaction.content,
@ -247,7 +247,7 @@
@@ -247,7 +247,7 @@
}
async function processReactions(reactionEvents: NostrEvent[]) {
console.lo g(`[FeedReactionButtons] Processing ${ reactionEvents . length } reactions for event ${ event . id . substring ( 0 , 16 )} ... (kind ${ event . kind } )`);
console.debu g(`[FeedReactionButtons] Processing ${ reactionEvents . length } reactions for event ${ event . id . substring ( 0 , 16 )} ... (kind ${ event . kind } )`);
const reactionMap = new Map< string , { content : string ; pubkeys : Set < string >; eventIds : Map < string , string > } > ();
const currentUser = sessionManager.getCurrentPubkey();
let skippedInvalid = 0;
@ -287,7 +287,7 @@
@@ -287,7 +287,7 @@
}
}
console.lo g(`[FeedReactionButtons] Processed reactions summary:`, {
console.debu g(`[FeedReactionButtons] Processed reactions summary:`, {
totalReactions: reactionEvents.length,
skippedInvalid,
reactionCounts: Array.from(reactionMap.entries()).map(([content, data]) => ({