mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2025-12-19 05:30:07 +08:00
fix(thesaurus): ingore empty seg
This commit is contained in:
parent
b4eb61e36a
commit
24955dc4a7
@ -287,6 +287,9 @@ func randreply(m map[string][]string) zero.Handler {
|
||||
text = strings.ReplaceAll(text, "{me}", nick)
|
||||
id := ctx.Event.MessageID
|
||||
for _, t := range strings.Split(text, "{segment}") {
|
||||
if t == "" {
|
||||
continue
|
||||
}
|
||||
process.SleepAbout1sTo2s()
|
||||
id = ctx.SendChain(message.Reply(id), message.Text(t))
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user