fix(openlist_driver): ensure UA is correctly propagated (#1679)

This commit is contained in:
Seven
2025-11-21 12:13:41 +08:00
committed by GitHub
parent c0d480366d
commit 3e37f575d8

View File

@@ -117,7 +117,7 @@ func (d *OpenList) Link(ctx context.Context, file model.Obj, args model.LinkArgs
if d.PassUAToUpsteam {
userAgent := args.Header.Get("user-agent")
if userAgent != "" {
headers["User-Agent"] = base.UserAgent
headers["User-Agent"] = userAgent
}
}
// if PassIPToUpsteam is true, then pass the ip address to the upstream