mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 13:27:08 +00:00
fix: filter empty message
This commit is contained in:
parent
802776cfa1
commit
43faf96cfe
1 changed files with 4 additions and 1 deletions
|
|
@ -16,7 +16,7 @@ import { EditCardTool } from '../utils/tools/EditCardTool.js'
|
|||
import { JinyanTool } from '../utils/tools/JinyanTool.js'
|
||||
import { KickOutTool } from '../utils/tools/KickOutTool.js'
|
||||
import { SetTitleTool } from '../utils/tools/SetTitleTool.js'
|
||||
import {SerpTool} from '../utils/tools/SerpTool.js'
|
||||
import { SerpTool } from '../utils/tools/SerpTool.js'
|
||||
import { SendMessageToSpecificGroupOrUserTool } from '../utils/tools/SendMessageToSpecificGroupOrUserTool.js'
|
||||
|
||||
export class bym extends plugin {
|
||||
|
|
@ -178,6 +178,9 @@ function filterResponseChunk (msg) {
|
|||
if (!msg || typeof msg !== 'string') {
|
||||
return false
|
||||
}
|
||||
if (!msg.trim()) {
|
||||
return false
|
||||
}
|
||||
if (msg.trim() === '```') {
|
||||
return false
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue