mirror of
https://github.com/Mrs4s/go-cqhttp.git
synced 2025-05-07 04:23:49 +08:00
fix light app.
This commit is contained in:
parent
49e3995129
commit
42434956d9
@ -51,6 +51,11 @@ func ToArrayMessage(e []message.IMessageElement, code int64, raw ...bool) (r []M
|
|||||||
"type": "text",
|
"type": "text",
|
||||||
"data": map[string]string{"text": o.Content},
|
"data": map[string]string{"text": o.Content},
|
||||||
}
|
}
|
||||||
|
case *message.LightAppElement:
|
||||||
|
m = MSG{
|
||||||
|
"type": "text",
|
||||||
|
"data": map[string]string{"text": o.Content},
|
||||||
|
}
|
||||||
case *message.AtElement:
|
case *message.AtElement:
|
||||||
if o.Target == 0 {
|
if o.Target == 0 {
|
||||||
m = MSG{
|
m = MSG{
|
||||||
@ -161,6 +166,8 @@ func ToStringMessage(e []message.IMessageElement, code int64, raw ...bool) (r st
|
|||||||
} else {
|
} else {
|
||||||
r += fmt.Sprintf(`[CQ:image,file=%s,url=%s]`, o.Filename, CQCodeEscapeValue(o.Url))
|
r += fmt.Sprintf(`[CQ:image,file=%s,url=%s]`, o.Filename, CQCodeEscapeValue(o.Url))
|
||||||
}
|
}
|
||||||
|
case *message.LightAppElement:
|
||||||
|
r += CQCodeEscapeText(o.Content)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
|
Loading…
x
Reference in New Issue
Block a user