Skip to content

Commit

Permalink
Merge pull request #354 from FlowiseAI/bugfix/first-message-not-found
Browse files Browse the repository at this point in the history
Bugfix/First Message Not Found
  • Loading branch information
HenryHengZJ authored Jun 17, 2023
2 parents 767b6c0 + d10dce0 commit ecf7b06
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/server/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -507,8 +507,8 @@ export class App {
})
if (!chatflow) return res.status(404).send(`Chatflow ${chatflowid} not found`)

const chatId = await getChatId(chatflow.id)
if (!chatId) return res.status(500).send(`Chatflow ${chatflowid} first message not found`)
let chatId = await getChatId(chatflow.id)
if (!chatId) chatId = Date.now().toString()

if (!isInternal) {
await this.validateKey(req, res, chatflow)
Expand Down

0 comments on commit ecf7b06

Please sign in to comment.