diff --git a/action/action.go b/action/action.go index dc05a83..957697e 100644 --- a/action/action.go +++ b/action/action.go @@ -2,6 +2,7 @@ package action import ( "encoding/json" + "fmt" "log" "strconv" "sync" @@ -44,7 +45,12 @@ func (am *actionManager) SendMsg(reply *model.Reply) error { ID: int(reply.FromMsg.OriginMsgId), }, } - reply.ReplyMsg = append([]any{replyMsg}, reply.ReplyMsg) + switch reply.ReplyMsg.(type) { + case []any: + reply.ReplyMsg = append([]any{replyMsg}, reply.ReplyMsg) + case string: + reply.ReplyMsg = fmt.Sprintf("%s%s", replyMsg.ToCQString(), reply.ReplyMsg) + } } userID := strconv.FormatInt(reply.FromMsg.UserId, 10) if reply.FromMsg.UserId == 0 {