Commit ff92f22d authored by Shuai's avatar Shuai

删除Param中的断言

parent 860006bf
......@@ -272,13 +272,8 @@ func (b *BeegoHttpRequest) SetProxy(proxy func(*http.Request) (*url.URL, error))
// Param adds query param in to request.
// params build query string as ?key1=value1&key2=value2...
func (b *BeegoHttpRequest) Param(key, value interface{}) *BeegoHttpRequest {
switch value.(type) {
case string:
b.params[key.(string)] = value.(string)
case []string:
b.params[key.(string)] = value.([]string)
}
func (b *BeegoHttpRequest) Param(key string, value interface{}) *BeegoHttpRequest {
b.params[key] = value
return b
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment