mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
Merge branch 'fix-event-deconstruct' into 'main'
fix: event deconstruct inside getAuthor See merge request soapbox-pub/ditto!129
This commit is contained in:
commit
417ff4ec59
1 changed files with 1 additions and 1 deletions
|
|
@ -40,7 +40,7 @@ const getAuthor = async (pubkey: string, opts: GetEventOpts = {}): Promise<Nostr
|
|||
const { relations = [], signal = AbortSignal.timeout(1000) } = opts;
|
||||
|
||||
return await optimizer.query([{ authors: [pubkey], kinds: [0], limit: 1 }], { limit: 1, signal })
|
||||
.then(([event]) => hydrateEvents({ events: [event], relations, storage: optimizer, signal }))
|
||||
.then((events) => hydrateEvents({ events, relations, storage: optimizer, signal }))
|
||||
.then(([event]) => event);
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue