From bb0ec5a25a714bf49614586efdb535cf6e539bbf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8B=A4=E5=BF=AB=E7=9A=84=E5=B0=8F=E6=99=B4=E5=90=8C?= =?UTF-8?q?=E5=AD=A6?= <941403820@qq.com> Date: Mon, 11 Mar 2024 01:33:01 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=94=99=E5=88=AB=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 勤快的小晴同学 <941403820@qq.com> --- iothub/client/mqttclient/rpc.go | 2 +- iothub/client/tcpclient/tcp.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/iothub/client/mqttclient/rpc.go b/iothub/client/mqttclient/rpc.go index 000a8f3..a15c8bd 100644 --- a/iothub/client/mqttclient/rpc.go +++ b/iothub/client/mqttclient/rpc.go @@ -37,7 +37,7 @@ func (rpc RpcRequest) Pub(deviceId, reqPayload string) error { topic := fmt.Sprintf(RpcRespTopic, rpc.RequestId) value, ok := Session.Load(deviceId) if !ok { - return errors.New("为获取到设备的MQTT连接") + return errors.New("未获取到设备的MQTT连接") } return Publish(topic, value.(string), reqPayload) } diff --git a/iothub/client/tcpclient/tcp.go b/iothub/client/tcpclient/tcp.go index 3a82420..6bc57ed 100644 --- a/iothub/client/tcpclient/tcp.go +++ b/iothub/client/tcpclient/tcp.go @@ -20,7 +20,7 @@ func Send(deviceId, msg string) error { } } else { global.Log.Infof("设备%s TCP连接不存在, 发送指令失败", deviceId) - return errors.New("为获取到设备的MQTT连接") + return errors.New("未获取到设备的MQTT连接") } return nil }