diff --git a/src/main/java/com/rarchives/ripme/ripper/rippers/Rule34Ripper.java b/src/main/java/com/rarchives/ripme/ripper/rippers/Rule34Ripper.java index 8651bd69..b7e0f7b0 100644 --- a/src/main/java/com/rarchives/ripme/ripper/rippers/Rule34Ripper.java +++ b/src/main/java/com/rarchives/ripme/ripper/rippers/Rule34Ripper.java @@ -33,6 +33,16 @@ public class Rule34Ripper extends AbstractHTMLRipper { return "rule34.xxx"; } + @Override + public boolean canRip(URL url){ + Pattern p = Pattern.compile("https?://rule34.xxx/index.php\\?page=post&s=list&tags=([\\S]+)"); + Matcher m = p.matcher(url.toExternalForm()); + if (m.matches()) { + return true; + } + return false; + } + @Override public String getGID(URL url) throws MalformedURLException { Pattern p = Pattern.compile("https?://rule34.xxx/index.php\\?page=post&s=list&tags=([\\S]+)"); @@ -41,7 +51,7 @@ public class Rule34Ripper extends AbstractHTMLRipper { return m.group(1); } throw new MalformedURLException("Expected rule34.xxx URL format: " + - "rule34.xxx/index.php\\?page=post&s=list&tags=TAG - got " + url + " instead"); + "rule34.xxx/index.php?page=post&s=list&tags=TAG - got " + url + " instead"); } public URL getAPIUrl() throws MalformedURLException {