mirror of
https://github.com/yusing/godoxy.git
synced 2025-06-01 01:22:34 +02:00
refactor: small refactor on maxmind code
This commit is contained in:
parent
32d8292b17
commit
371e756307
1 changed files with 9 additions and 4 deletions
|
@ -34,11 +34,16 @@ type (
|
||||||
City = maxmind.City
|
City = maxmind.City
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
const (
|
||||||
updateInterval = 24 * time.Hour
|
updateInterval = 24 * time.Hour
|
||||||
httpClient = &http.Client{
|
updateTimeout = 10 * time.Second
|
||||||
Timeout: 10 * time.Second,
|
)
|
||||||
}
|
|
||||||
|
var httpClient = &http.Client{
|
||||||
|
Timeout: updateTimeout,
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
ErrResponseNotOK = gperr.New("response not OK")
|
ErrResponseNotOK = gperr.New("response not OK")
|
||||||
ErrDownloadFailure = gperr.New("download failure")
|
ErrDownloadFailure = gperr.New("download failure")
|
||||||
)
|
)
|
||||||
|
|
Loading…
Add table
Reference in a new issue