From 91c17d3a873497b04af4a0b0faabc3a74f672b36 Mon Sep 17 00:00:00 2001 From: lychang <632945494@qq.com> Date: Fri, 12 Jan 2024 13:46:30 +0800 Subject: [PATCH] update get_response --- src/web_parser.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/web_parser.rs b/src/web_parser.rs index 4cf0c07..a1d1dfc 100644 --- a/src/web_parser.rs +++ b/src/web_parser.rs @@ -51,7 +51,7 @@ fn download_image(url_path: &str, file_path: &str, retry_times: i8) -> i8 { } if flag == 2 && retry_times > 1 { thread::sleep(Duration::from_millis(5000)); - download_image(url_path, file_path, retry_times - 1) + return download_image(url_path, file_path, retry_times - 1) } return flag; }