mirror of
https://gitlab.com/soapbox-pub/mkstack.git
synced 2025-08-28 05:29:23 +00:00
fix: increase timeout to 3 seconds
This commit is contained in:
parent
f5cbf3bcd1
commit
339acb2bc8
@ -14,7 +14,7 @@ export function useAuthor(pubkey: string | undefined) {
|
|||||||
|
|
||||||
const [event] = await nostr.query(
|
const [event] = await nostr.query(
|
||||||
[{ kinds: [0], authors: [pubkey!], limit: 1 }],
|
[{ kinds: [0], authors: [pubkey!], limit: 1 }],
|
||||||
{ signal: AbortSignal.any([signal, AbortSignal.timeout(500)]) },
|
{ signal: AbortSignal.any([signal, AbortSignal.timeout(3000)]) },
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!event) {
|
if (!event) {
|
||||||
|
@ -22,7 +22,7 @@ export function useLoggedInAccounts() {
|
|||||||
try {
|
try {
|
||||||
events = await nostr.query(
|
events = await nostr.query(
|
||||||
[{ kinds: [0], authors: logins.map((l) => l.pubkey) }],
|
[{ kinds: [0], authors: logins.map((l) => l.pubkey) }],
|
||||||
{ signal: AbortSignal.any([signal, AbortSignal.timeout(500)]) },
|
{ signal: AbortSignal.any([signal, AbortSignal.timeout(3000)]) },
|
||||||
);
|
);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Error fetching accounts:', error);
|
console.error('Error fetching accounts:', error);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user