mirror of
https://github.com/LLOneBot/LLOneBot.git
synced 2024-11-22 01:56:33 +00:00
refactor
This commit is contained in:
@@ -19,8 +19,8 @@ abstract class ForwardSingleMsg extends BaseAction<Payload, null> {
|
||||
}
|
||||
const peer = await createPeer(this.ctx, payload)
|
||||
const ret = await this.ctx.ntMsgApi.forwardMsg(msg.peer, peer, [msg.msgId])
|
||||
if (ret.result !== 0) {
|
||||
throw new Error(`转发消息失败 ${ret.errMsg}`)
|
||||
if (ret.length === 0) {
|
||||
throw new Error(`转发消息失败`)
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
Reference in New Issue
Block a user