fix: 在 fetchSelf 函数中初始化 reply 变量以确保返回值的正确性

This commit is contained in:
lixiangwuxian
2025-04-11 00:51:01 +08:00
parent 893c4ae887
commit 98c9073f0d
2 changed files with 2 additions and 5 deletions

View File

@@ -2,7 +2,6 @@ package util
import (
"bytes"
"crypto/tls"
"fmt"
"io"
"net/url"
@@ -72,10 +71,7 @@ func DownloadFile(urlStr string, dirPath string) (filepath string, err error) {
ReadTimeout: 30 * time.Second,
WriteTimeout: 30 * time.Second,
MaxConnWaitTimeout: 30 * time.Second,
// TLSConfig: nil, // 使用默认配置
TLSConfig: &tls.Config{
InsecureSkipVerify: true,
},
TLSConfig: nil,
}
// 准备请求