mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-17 17:00:15 +01:00
fix: rm short filter
This commit is contained in:
parent
8624062488
commit
78b4004ead
3 changed files with 3 additions and 3 deletions
|
|
@ -18,7 +18,7 @@ router.use('/sydney', askSydney);
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
||||||
let { model, text, parentMessageId, conversationId, chatGptLabel, promptPrefix } = req.body;
|
let { model, text, parentMessageId, conversationId, chatGptLabel, promptPrefix } = req.body;
|
||||||
if (!text.trim().includes(' ') && text.length < 5) {
|
if (text.length === 0) {
|
||||||
return handleError(res, 'Prompt empty or too short');
|
return handleError(res, 'Prompt empty or too short');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ const citationRegex = /\[\^\d+?\^]/g;
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
||||||
const { model, text, ...convo } = req.body;
|
const { model, text, ...convo } = req.body;
|
||||||
if (!text.trim().includes(' ') && text.length < 5) {
|
if (text.length === 0) {
|
||||||
return handleError(res, 'Prompt empty or too short');
|
return handleError(res, 'Prompt empty or too short');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ const citationRegex = /\[\^\d+?\^]/g;
|
||||||
|
|
||||||
router.post('/', async (req, res) => {
|
router.post('/', async (req, res) => {
|
||||||
const { model, text, ...convo } = req.body;
|
const { model, text, ...convo } = req.body;
|
||||||
if (!text.trim().includes(' ') && text.length < 5) {
|
if (text.length === 0) {
|
||||||
return handleError(res, 'Prompt empty or too short');
|
return handleError(res, 'Prompt empty or too short');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue