diff --git a/src/rust/wpcomics/sources/xoxocomics/res/source.json b/src/rust/wpcomics/sources/xoxocomics/res/source.json index acc1e51fa..93f76c71f 100644 --- a/src/rust/wpcomics/sources/xoxocomics/res/source.json +++ b/src/rust/wpcomics/sources/xoxocomics/res/source.json @@ -3,7 +3,7 @@ "id": "en.xoxocomics", "lang": "en", "name": "XOXO Comics", - "version": 2, + "version": 3, "url": "https://xoxocomic.com/", "nsfw": 1 }, diff --git a/src/rust/wpcomics/sources/xoxocomics/src/helper.rs b/src/rust/wpcomics/sources/xoxocomics/src/helper.rs index 238cab0b4..da51939c2 100644 --- a/src/rust/wpcomics/sources/xoxocomics/src/helper.rs +++ b/src/rust/wpcomics/sources/xoxocomics/src/helper.rs @@ -2,10 +2,10 @@ use aidoku::{prelude::format, std::String}; pub fn listing_map(listing: String) -> String { let url: &str = match listing.as_str() { - "Popular" => "popular-comics", - "Hot" => "hot", - "Completed" => "status/completed", - "Ongoing" => "status/ongoing", + "Popular" => "popular-comic", + "Hot" => "hot-comic", + "Completed" => "completed-comic", + "Ongoing" => "ongoing-comic", _ => "", }; String::from(url) @@ -14,9 +14,9 @@ pub fn listing_map(listing: String) -> String { // MARK: Other utilities pub fn get_search_url(base_url: String, query: String, genre: String, page: i32) -> String { if !query.is_empty() { - format!("{base_url}/search?page={page}&keyword={query}") + format!("{base_url}/search-comic?keyword={query}&page={page}") } else if !genre.is_empty() { - format!("{base_url}/genre/{genre}?page={page}") + format!("{base_url}/{genre}-comic?page={page}") } else { base_url } diff --git a/src/rust/wpcomics/sources/xoxocomics/src/lib.rs b/src/rust/wpcomics/sources/xoxocomics/src/lib.rs index 23c2be5f5..2c36a1d5b 100644 --- a/src/rust/wpcomics/sources/xoxocomics/src/lib.rs +++ b/src/rust/wpcomics/sources/xoxocomics/src/lib.rs @@ -73,7 +73,7 @@ fn get_page_list(_manga_id: String, chapter_id: String) -> Result> { #[modify_image_request] fn modify_image_request(request: Request) { template::modify_image_request( - String::from("https://xoxocomics.com"), + String::from("https://xoxocomic.com"), String::from("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36 Edg/101.0.1210.39"), request, )