mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-26 15:24:51 +02:00
Added better solution to issue #968
This commit is contained in:
@@ -563,10 +563,6 @@ public abstract class AbstractRipper
|
||||
LOGGER.error("Got exception while running ripper:", e);
|
||||
waitForThreads();
|
||||
sendUpdate(STATUS.RIP_ERRORED, "HTTP status code " + e.getStatusCode() + " for URL " + e.getUrl());
|
||||
}catch(NullPointerException e){
|
||||
LOGGER.error("Got null pointer exception while running ripper:", e);
|
||||
waitForThreads();
|
||||
sendUpdate(STATUS.NO_ALBUM_OR_USER, "Album or user doesn't exist!");
|
||||
} catch (Exception e) {
|
||||
LOGGER.error("Got exception while running ripper:", e);
|
||||
waitForThreads();
|
||||
|
@@ -171,6 +171,10 @@ public class TumblrRipper extends AlbumRipper {
|
||||
HttpStatusException status = (HttpStatusException)cause;
|
||||
if (status.getStatusCode() == HttpURLConnection.HTTP_UNAUTHORIZED && !useDefaultApiKey) {
|
||||
retry = true;
|
||||
} else if (status.getStatusCode() == 404) {
|
||||
LOGGER.error("No user or album found!");
|
||||
sendUpdate(STATUS.NO_ALBUM_OR_USER, "Album or user doesn't exist!");
|
||||
break;
|
||||
} else if (status.getStatusCode() == 429) {
|
||||
LOGGER.error("Tumblr rate limit has been exceeded");
|
||||
sendUpdate(STATUS.DOWNLOAD_ERRORED,"Tumblr rate limit has been exceeded");
|
||||
|
Reference in New Issue
Block a user