mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-22 21:43:06 +02:00
Added getAlbumTitle support to hentaifox ripper
This commit is contained in:
@@ -58,6 +58,19 @@ public class HentaifoxRipper extends AbstractHTMLRipper {
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getAlbumTitle(URL url) throws MalformedURLException {
|
||||
try {
|
||||
Document doc = getFirstPage();
|
||||
String title = doc.select("div.info > h1").first().text();
|
||||
return getHost() + "_" + title + "_" + getGID(url);
|
||||
} catch (Exception e) {
|
||||
// Fall back to default album naming convention
|
||||
LOGGER.warn("Failed to get album title from " + url, e);
|
||||
}
|
||||
return super.getAlbumTitle(url);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void downloadURL(URL url, int index) {
|
||||
addURLToDownload(url, getPrefix(index));
|
||||
|
Reference in New Issue
Block a user