From 2ceb31b8e5f95bb97e560880a2cace8827bd866b Mon Sep 17 00:00:00 2001 From: cdle <798731886@qq.com> Date: Tue, 12 Oct 2021 16:55:34 +0800 Subject: [PATCH] update --- core/xiaoai.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/xiaoai.go b/core/xiaoai.go index 63ccb06..92217f0 100644 --- a/core/xiaoai.go +++ b/core/xiaoai.go @@ -2,6 +2,7 @@ package core import ( "fmt" + "strings" "time" "github.com/beego/beego/v2/client/httplib" @@ -11,7 +12,7 @@ func init() { AddCommand("", []Function{ { Rules: []string{ - "^小爱同学$", + "^小爱(.*)$", }, Handle: func(s Sender) interface{} { api := sillyGirl.Get("小爱同学") @@ -26,7 +27,7 @@ func init() { return str } msg := s.Get() - if msg == "对话模式" { + if strings.Contains(msg, "对话模式") { stop := false for { if stop {