diff --git a/src/controllers/api/accounts.ts b/src/controllers/api/accounts.ts index a2c1884..79934fe 100644 --- a/src/controllers/api/accounts.ts +++ b/src/controllers/api/accounts.ts @@ -73,9 +73,9 @@ const accountController: AppController = async (c) => { const event = await getAuthor(pubkey); if (event) { return c.json(await renderAccount(event)); + } else { + return c.json(await accountFromPubkey(pubkey)); } - - return c.json({ error: 'Could not find user.' }, 404); }; const accountLookupController: AppController = async (c) => {