Skip to content

Commit

Permalink
fix:合并转发elements转换错误
Browse files Browse the repository at this point in the history
  • Loading branch information
sj817 committed Apr 8, 2024
1 parent 904d63e commit 2dcf391
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/adapter/kritor/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export default class extends EventEmitter {
_elements.push(new kritor.common.ReplyElement({ type, reply: { id } }))
break
}
case 'VOICE': {
case 'voice': {
const { VOICE: type } = ElementType
const { file } = i
_elements.push(new kritor.common.VoiceElement({ type, voice: { file } }))
Expand Down Expand Up @@ -208,6 +208,7 @@ export default class extends EventEmitter {
const service = 'MessageService'
const cmd = 'UploadForwardMessage'
const type = 'message'
messages = this.elements(messages)
const buf = { contact, messages, retry_count }
let res = await this.Serialization(service, cmd, type, buf)
return res
Expand All @@ -220,6 +221,7 @@ export default class extends EventEmitter {
const type = 'message'
const buf = { res_id }
let res = await this.Serialization(service, cmd, type, buf)
res.messages = this.elements(res.messages)
return res
}

Expand Down

0 comments on commit 2dcf391

Please sign in to comment.