Skip to content

Commit

Permalink
chore: send error message when gen_title fails
Browse files Browse the repository at this point in the history
  • Loading branch information
danny-avila committed Feb 4, 2024
1 parent e6ce7f5 commit 7bf11d7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion api/server/routes/convos.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,11 @@ router.post('/gen_title', async (req, res) => {
await titleCache.delete(key);
res.status(200).json({ title });
} else {
res.status(404).end();
res
.status(404)
.json({
message: 'Title not found or method not implemented for the conversation\'s endpoint',
});
}
});

Expand Down

0 comments on commit 7bf11d7

Please sign in to comment.