diff --git a/src/main/java/com/rarchives/ripme/ripper/rippers/WebtoonsRipper.java b/src/main/java/com/rarchives/ripme/ripper/rippers/WebtoonsRipper.java index dba049cc..96471c72 100644 --- a/src/main/java/com/rarchives/ripme/ripper/rippers/WebtoonsRipper.java +++ b/src/main/java/com/rarchives/ripme/ripper/rippers/WebtoonsRipper.java @@ -88,4 +88,16 @@ public class WebtoonsRipper extends AbstractHTMLRipper { cookies = resp.cookies(); return Http.url(url).get(); } + + @Override + public Document getNextPage(Document doc) throws IOException { + // Find next page + String nextUrl = ""; + Element elem = doc.select("a.pg_next").first(); + nextUrl = elem.attr("href"); + if (nextUrl == "") { + throw new IOException("No more pages"); + } + return Http.url(nextUrl).get(); + } }