diff --git a/common/req.go b/common/req.go index aaad23a..a650f1a 100644 --- a/common/req.go +++ b/common/req.go @@ -2,6 +2,7 @@ package common import ( "path/filepath" + "time" "github.com/imroc/req/v3" "github.com/krau/SaveAny-Bot/config" @@ -10,7 +11,7 @@ import ( var ReqClient *req.Client func initClient() { - ReqClient = req.NewClient().SetOutputDirectory(config.Cfg.Temp.BasePath) + ReqClient = req.NewClient().SetOutputDirectory(config.Cfg.Temp.BasePath).SetTimeout(86400 * time.Second) } func GetDownloadedFilePath(filename string) string {