Compare commits

..

No commits in common. "ca6b3d4eb2a5d2b4c3a5041287ba947653ac0fe9" and "8a3574cd48b6faabc57bb0c1c9a5f070b3ad4f39" have entirely different histories.

2 changed files with 2 additions and 5 deletions

View File

@ -12,7 +12,7 @@ import (
) )
const ( const (
VERSION string = "0.5.501" VERSION string = "0.5.5"
DefaultUserAgent string = "Dodo/" + VERSION DefaultUserAgent string = "Dodo/" + VERSION
ProxyCheckURL string = "https://www.google.com" ProxyCheckURL string = "https://www.google.com"
DefaultMethod string = "GET" DefaultMethod string = "GET"
@ -79,7 +79,7 @@ func (config *RequestConfig) Print() {
t.AppendSeparator() t.AppendSeparator()
t.AppendRow(table.Row{"Cookies", string(utils.PrettyJSONMarshal(config.Cookies, 3, "", " "))}) t.AppendRow(table.Row{"Cookies", string(utils.PrettyJSONMarshal(config.Cookies, 3, "", " "))})
t.AppendSeparator() t.AppendSeparator()
t.AppendRow(table.Row{"Proxies", string(utils.PrettyJSONMarshal(config.Proxies, 3, "", " "))}) t.AppendRow(table.Row{"Proxies Count", string(utils.PrettyJSONMarshal(config.Proxies, 3, "", " "))})
t.AppendSeparator() t.AppendSeparator()
t.AppendRow(table.Row{"Proxy Check", !config.NoProxyCheck}) t.AppendRow(table.Row{"Proxy Check", !config.NoProxyCheck})
t.AppendSeparator() t.AppendSeparator()

View File

@ -17,9 +17,6 @@ func (t TruncatedMarshaller) MarshalJSON() ([]byte, error) {
if val.Kind() != reflect.Slice && val.Kind() != reflect.Array { if val.Kind() != reflect.Slice && val.Kind() != reflect.Array {
return json.Marshal(t.Value) return json.Marshal(t.Value)
} }
if val.Len() == 0 {
return []byte("[]"), nil
}
length := val.Len() length := val.Len()
if length <= t.MaxItems { if length <= t.MaxItems {