diff --git a/api/app/bingai.js b/api/app/bingai.js index d1175c0bfc..2ccbc2b356 100644 --- a/api/app/bingai.js +++ b/api/app/bingai.js @@ -22,8 +22,10 @@ const askBing = async ({ text, progressCallback, convo }) => { options = { ...options, ...convo }; } - const res = await bingAIClient.sendMessage(text, options - ); + if (options?.jailbreakConversationId == 'false') + options.jailbreakConversationId = false + + const res = await bingAIClient.sendMessage(text, options); return res; diff --git a/api/models/Conversation.js b/api/models/Conversation.js index 1c994fdc38..d2ead788d2 100644 --- a/api/models/Conversation.js +++ b/api/models/Conversation.js @@ -64,6 +64,8 @@ module.exports = { if (title) { update.title = title; } + if (!update.jailbreakConversationId) + update.jailbreakConversationId = null return await Conversation.findOneAndUpdate( { conversationId },