From f393060907f9567a433485838f0f5287b64273f8 Mon Sep 17 00:00:00 2001 From: cyian-1756 Date: Thu, 10 Aug 2017 10:12:10 -0400 Subject: [PATCH] Changed 8muses image host --- .../rarchives/ripme/ripper/rippers/EightmusesRipper.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/rarchives/ripme/ripper/rippers/EightmusesRipper.java b/src/main/java/com/rarchives/ripme/ripper/rippers/EightmusesRipper.java index 21a260cb..5aa66c0a 100644 --- a/src/main/java/com/rarchives/ripme/ripper/rippers/EightmusesRipper.java +++ b/src/main/java/com/rarchives/ripme/ripper/rippers/EightmusesRipper.java @@ -84,13 +84,13 @@ public class EightmusesRipper extends AbstractHTMLRipper { List imageURLs = new ArrayList(); // get the first image link on the page and check if the last char in it is a number // if it is a number then we're ripping a comic if not it's a subalbum - String firstImageLink = page.select(".page-gallery > div > div > div.gallery > a.t-hover").first().attr("href"); + String firstImageLink = page.select("div.gallery > a.t-hover").first().attr("href"); Pattern p = Pattern.compile("/comix/([a-zA-Z0-9\\-_/]*/)?\\d+"); Matcher m = p.matcher(firstImageLink); if (!m.matches()) { logger.info("Ripping subalbums"); // Page contains subalbums (not images) - Elements albumElements = page.select(".page-gallery > div > div > div.gallery > a.t-hover"); + Elements albumElements = page.select("div.gallery > a.t-hover"); List albumsList = albumElements.subList(0, albumElements.size()); Collections.reverse(albumsList); // Iterate over elements in reverse order @@ -173,7 +173,7 @@ public class EightmusesRipper extends AbstractHTMLRipper { sendUpdate(STATUS.LOADING_RESOURCE, imageUrl); Document doc = new Http(imageUrl).get(); // Retrieve the webpage of the image URL Element fullSizeImage = doc.select(".photo").first(); // Select the "photo" element from the page (there should only be 1) - String path = "https://cdn.ampproject.org/i/s/www.8muses.com/data/fu/small/" + fullSizeImage.children().select("#imageName").attr("value"); // Append the path to the fullsize image file to the standard prefix + String path = "https://cdn.ampproject.org/i/s/www.8muses.com/data/ufu/small/" + fullSizeImage.children().select("#imageName").attr("value"); // Append the path to the fullsize image file to the standard prefix return path; }