verify_credentials: try calling the database directly

This commit is contained in:
Alex Gleason 2024-05-06 11:21:38 -05:00
parent f4c02f1568
commit 7007d7e81b
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7

View file

@ -47,7 +47,7 @@ const createAccountController: AppController = async (c) => {
const verifyCredentialsController: AppController = async (c) => {
const pubkey = c.get('pubkey')!;
const event = await getAuthor(pubkey, { relations: ['author_stats'] });
const [event] = await Storages.db.query([{ kinds: [0], authors: [pubkey], limit: 1 }]);
if (event) {
return c.json(await renderAccount(event, { withSource: true }));
} else {