mirror of
https://github.com/sipeed/picoclaw.git
synced 2026-06-12 18:08:54 +00:00
Update pkg/channels/wecom/aibot.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -928,9 +928,12 @@ func (c *WeComAIBotChannel) encryptResponse(
|
||||
return string(respJSON)
|
||||
}
|
||||
|
||||
// encryptEmptyResponse returns empty encrypted response
|
||||
// encryptEmptyResponse returns a minimal valid encrypted response
|
||||
func (c *WeComAIBotChannel) encryptEmptyResponse(timestamp, nonce string) string {
|
||||
return ""
|
||||
// Construct a zero-value stream response and encrypt it so that
|
||||
// WeCom always receives a syntactically valid encrypted JSON object.
|
||||
emptyResp := WeComAIBotStreamResponse{}
|
||||
return c.encryptResponse("", timestamp, nonce, emptyResp)
|
||||
}
|
||||
|
||||
// encryptMessage encrypts a plain text message for WeCom AI Bot
|
||||
|
||||
Reference in New Issue
Block a user