Skip to content

Commit

Permalink
Display only last message on load
Browse files Browse the repository at this point in the history
  • Loading branch information
evgenius1424 committed Oct 27, 2024
1 parent 07d259e commit a39b6f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/learnbefore-bff/api/chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ app.get(
expressAsyncHandler(async function (req, res) {
try {
const user = await getUser(req.auth.userId)
const messages = await store.getUserMessages(user.id, 5)
const messages = await store.getUserMessages(user.id, 1)
res.status(200).json(messages)
} catch (error) {
res.status(500).json({ message: "Error fetching chat messages" })
Expand Down

0 comments on commit a39b6f9

Please sign in to comment.