debug: add detailed logging to fetchBookmarks function

- Add console logs to track if fetchBookmarks is called
- Log early return conditions
- This will help identify why the function might not be executing
This commit is contained in:
Gigi
2025-10-02 09:14:24 +02:00
parent 6481dd1bed
commit 774ce0f1bf

View File

@@ -74,7 +74,11 @@ const Bookmarks: React.FC<BookmarksProps> = ({ relayPool, onLogout }) => {
}, [relayPool, activeAccount?.pubkey]) // Only depend on pubkey, not the entire activeAccount object
const fetchBookmarks = async () => {
if (!relayPool || !activeAccount || loading) return
console.log('🔍 fetchBookmarks called, loading:', loading)
if (!relayPool || !activeAccount || loading) {
console.log('🔍 fetchBookmarks early return - relayPool:', !!relayPool, 'activeAccount:', !!activeAccount, 'loading:', loading)
return
}
try {
setLoading(true)