Fix NostrSync error toast for accounts with no profile published yet
Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
This commit is contained in:
parent
6e46214747
commit
0f98994c86
1 changed files with 11 additions and 5 deletions
|
|
@ -215,6 +215,11 @@ export function NostrSync() {
|
||||||
} else {
|
} else {
|
||||||
syncState.current.set(pubkey, false);
|
syncState.current.set(pubkey, false);
|
||||||
console.error('[NostrSync] All attempts failed for', pubkey.slice(0, 8));
|
console.error('[NostrSync] All attempts failed for', pubkey.slice(0, 8));
|
||||||
|
// Don't show error toast if profile simply doesn't exist yet —
|
||||||
|
// it's a new account, not a connection error
|
||||||
|
if (!profileSynced) {
|
||||||
|
console.log('[NostrSync] No profile found — may be a new account');
|
||||||
|
} else {
|
||||||
toast({
|
toast({
|
||||||
title: 'Could not load profile',
|
title: 'Could not load profile',
|
||||||
description: 'Check your internet connection and try refreshing.',
|
description: 'Check your internet connection and try refreshing.',
|
||||||
|
|
@ -223,6 +228,7 @@ export function NostrSync() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue