浏览代码

Fixed HDSv2 execute url escape bug

Toby Chui 3 年之前
父节点
当前提交
53e188aad4
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      mod/iot/hdsv2/hdsv2.go

+ 1 - 1
mod/iot/hdsv2/hdsv2.go

@@ -134,7 +134,7 @@ func (h *Handler) Execute(device *iot.Device, endpoint *iot.Endpoint, payload in
 
 	} else {
 		//Payload exists. Append it to the end with value=?
-		targetURL += "?value=" + payload.(string)
+		targetURL += "?value=" + url.QueryEscape(payload.(string))
 	}
 
 	result, err := tryGet(targetURL)