mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-12 00:44:03 +02:00
Delay rip if video
This commit is contained in:
@@ -279,8 +279,16 @@ public class ChanRipper extends AbstractHTMLRipper {
|
|||||||
return imageURLs;
|
return imageURLs;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean isVideo(URL url) {
|
||||||
|
String urlString = url.toExternalForm();
|
||||||
|
return urlString.endsWith(".webm") || urlString.endsWith(".mp4");
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void downloadURL(URL url, int index) {
|
public void downloadURL(URL url, int index) {
|
||||||
|
if (isVideo(url)) {
|
||||||
|
sleep(1000);
|
||||||
|
}
|
||||||
addURLToDownload(url, getPrefix(index));
|
addURLToDownload(url, getPrefix(index));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user