From f96cf1127c43f5f81eefce56f4bc7461eee687ed Mon Sep 17 00:00:00 2001 From: Looly Date: Thu, 27 Apr 2023 12:05:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DHttpDownloader.downloadFile?= =?UTF-8?q?=20=E6=96=B9=E6=B3=95=E7=BC=BA=E5=B0=91static=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- hutool-http/src/main/java/cn/hutool/http/HttpDownloader.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 90de4a767..b9c8e84e1 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ # 🚀Changelog ------------------------------------------------------------------------------------------------------------- -# 5.8.19.M1 (2023-04-25) +# 5.8.19.M1 (2023-04-27) ### 🐣新特性 * 【db 】 优化HttpRequest.toString()内容打印(issue#3072@Github) @@ -13,6 +13,7 @@ * 【core 】 修复VIN(车架号)正则问题(pr#3078@Github) * 【core 】 修复HtmlUtil的removeHtmlAttr方法匹配问题(issue#I6YNTF@Gitee) * 【core 】 修复JSONUtil.toBean目标存在Map字段无序问题(issue#I6YN2A@Gitee) +* 【http 】 修复HttpDownloader.downloadFile 方法缺少static问题(issue#I6Z8VU@Gitee) ------------------------------------------------------------------------------------------------------------- # 5.8.18 (2023-04-16) diff --git a/hutool-http/src/main/java/cn/hutool/http/HttpDownloader.java b/hutool-http/src/main/java/cn/hutool/http/HttpDownloader.java index b2aaf9500..4c98f4f00 100644 --- a/hutool-http/src/main/java/cn/hutool/http/HttpDownloader.java +++ b/hutool-http/src/main/java/cn/hutool/http/HttpDownloader.java @@ -66,7 +66,7 @@ public class HttpDownloader { * @return 下载大小 * @since 5.7.12 */ - public long downloadFile(String url, File targetFileOrDir, String tempFileSuffix, int timeout, StreamProgress streamProgress) { + public static long downloadFile(String url, File targetFileOrDir, String tempFileSuffix, int timeout, StreamProgress streamProgress) { return requestDownload(url, timeout).writeBody(targetFileOrDir, tempFileSuffix, streamProgress); }