Skip to content

Commit

Permalink
fix: filter empty message
Browse files Browse the repository at this point in the history
  • Loading branch information
ikechan8370 committed Jan 2, 2025
1 parent 802776c commit 43faf96
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion apps/bym.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down Expand Up @@ -178,6 +178,9 @@ function filterResponseChunk (msg) {
if (!msg || typeof msg !== 'string') {
return false
}
if (!msg.trim()) {
return false
}
if (msg.trim() === '```') {
return false
}
Expand Down

0 comments on commit 43faf96

Please sign in to comment.