1
0
mirror of https://github.com/Mrs4s/go-cqhttp.git synced 2025-05-05 19:43:49 +08:00

Merge pull request #316 from XYenon/patch-1

Fix empty message segment
This commit is contained in:
Mrs4s 2020-09-24 00:47:01 +08:00 committed by GitHub
commit a9d53f038f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -58,8 +58,6 @@ func ToArrayMessage(e []message.IMessageElement, code int64, raw ...bool) (r []M
"type": "text",
"data": map[string]string{"text": o.Content},
}
case *message.ReplyElement:
continue
case *message.LightAppElement:
//m = MSG{
// "type": "text",
@ -144,6 +142,8 @@ func ToArrayMessage(e []message.IMessageElement, code int64, raw ...bool) (r []M
"data": map[string]string{"data": o.Content, "resid": fmt.Sprintf("%d", o.Id)},
}
}
default:
continue
}
r = append(r, m)
}