2 Commits

Author SHA1 Message Date
eson
20b353780b fix(packagename): fix name error 2020-11-23 16:09:08 +08:00
eson
eda1ba83ab feat(label): send label and log label. easy for debug 2020-11-23 12:21:36 +08:00
2 changed files with 2 additions and 1 deletions

View File

@@ -167,6 +167,7 @@ func (cli *Client) Open(label, urlstr string) (bodyRes string, ok bool) {
data := url.Values{} data := url.Values{}
data["url"] = []string{urlstr} data["url"] = []string{urlstr}
data["callback"] = []string{cli.host + ":" + cli.port + "/" + callback.(Callback).hash} data["callback"] = []string{cli.host + ":" + cli.port + "/" + callback.(Callback).hash}
data["label"] = []string{label}
resp, err := http.DefaultClient.PostForm(cli.chromeProxyAddr+"/task/put", data) resp, err := http.DefaultClient.PostForm(cli.chromeProxyAddr+"/task/put", data)
if err != nil { if err != nil {
panic(err) panic(err)

View File

@@ -1,4 +1,4 @@
package cplient package cpclient
import ( import (
"fmt" "fmt"