SendUserMessage中限制钉钉消息长度的BUG
This commit is contained in:
@@ -31,7 +31,7 @@ func SendUserMessage(msgType, userID, title, content string) (err error) {
|
||||
for _, auth := range authList {
|
||||
if auth.Type == dingding.AuthTypeStaff || auth.Type == weixin.AuthTypeMP {
|
||||
findOneMethod = true
|
||||
if msgType == dingdingapi.MsgTypeMarkdown && len(content) > dingdingapi.MaxWorkContentLen {
|
||||
if len(content) > dingdingapi.MaxWorkContentLen {
|
||||
content = content[:dingdingapi.MaxWorkContentLen-4] + "..."
|
||||
}
|
||||
err = SendDDUserMessage(msgType, auth.AuthID, title, content)
|
||||
|
||||
Reference in New Issue
Block a user