This repository has been archived on 2022-09-04. You can view files and clone it, but cannot push or open issues or pull requests.
shared/tw/twdataloader/config.go

20 lines
235 B
Go

package twdataloader
import (
"net/http"
"time"
)
type Config struct {
BaseURL string
Client *http.Client
}
func (cfg *Config) Init() {
if cfg.Client == nil {
cfg.Client = &http.Client{
Timeout: 5 * time.Second,
}
}
}