Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,8 +294,8 @@ func (c *Client) SetHeaders(h map[string]string) *Client {

// Param returns all values of the specified query parameter.
func (c *Client) Param(key string) []string {
res := []string{}
tmp := c.params.PeekMulti(key)
res := make([]string, 0, len(tmp))
for _, v := range tmp {
res = append(res, utils.UnsafeString(v))
}
Expand Down
2 changes: 1 addition & 1 deletion client/request.go
Original file line number Diff line number Diff line change
Expand Up @@ -447,8 +447,8 @@ func (r *Request) resetBody(t bodyType) {

// FormData returns all values associated with a form field.
func (r *Request) FormData(key string) []string {
var res []string
tmp := r.formData.PeekMulti(key)
res := make([]string, 0, len(tmp))
for _, v := range tmp {
res = append(res, utils.UnsafeString(v))
}
Expand Down
Loading