From 759a8e48b3bc3727379c03efc2dcc40559f85a8f Mon Sep 17 00:00:00 2001 From: Zastian Pretorius Date: Mon, 26 Sep 2022 15:51:36 +0100 Subject: [PATCH] fixed yet anothe gogo url change --- src/anime/scraper.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/anime/scraper.rs b/src/anime/scraper.rs index 3b231a7..f75c268 100644 --- a/src/anime/scraper.rs +++ b/src/anime/scraper.rs @@ -11,7 +11,6 @@ pub fn get_anime_html(url: &str) -> String { ) .body(()) .unwrap(); - req.send().unwrap().text().unwrap() } @@ -32,7 +31,7 @@ pub fn get_ep_location(url: &str) -> String { } pub fn anime_names(query: String) -> Vec { - let url = format!("https://www1.gogoanime.ee//search.html?keyword={}", query); + let url = format!("https://www2.gogoanime.ee//search.html?keyword={}", query); //relpace all spaces with %20 let url = url.replace(' ', "%20"); let html = get_anime_html(&url); @@ -47,7 +46,7 @@ pub fn anime_names(query: String) -> Vec { } pub fn anime_ep_range(anime_name: &str) -> u16 { - let url = format!("https://www1.gogoanime.ee/category/{}", anime_name); + let url = format!("https://www2.gogoanime.ee/category/{}", anime_name); let re = Regex::new(r#"(?m)\s"#).unwrap(); let episodes = re .captures_iter(&get_anime_html(&url))