mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-09-02 18:33:13 +02:00
new URI instead of new URL, photobucketrupper.
This commit is contained in:
@@ -2,6 +2,8 @@ package com.rarchives.ripme.ripper.rippers;
|
|||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.MalformedURLException;
|
import java.net.MalformedURLException;
|
||||||
|
import java.net.URI;
|
||||||
|
import java.net.URISyntaxException;
|
||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -82,7 +84,7 @@ public class PhotobucketRipper extends AbstractHTMLRipper {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public URL sanitizeURL(URL url) throws MalformedURLException {
|
public URL sanitizeURL(URL url) throws MalformedURLException, URISyntaxException {
|
||||||
LOGGER.info(url);
|
LOGGER.info(url);
|
||||||
String u = url.toExternalForm();
|
String u = url.toExternalForm();
|
||||||
if (u.contains("?")) {
|
if (u.contains("?")) {
|
||||||
@@ -93,11 +95,11 @@ public class PhotobucketRipper extends AbstractHTMLRipper {
|
|||||||
// append trailing slash
|
// append trailing slash
|
||||||
u = u + "/";
|
u = u + "/";
|
||||||
}
|
}
|
||||||
return new URL(u);
|
return new URI(u).toURL();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getGID(URL url) throws MalformedURLException {
|
public String getGID(URL url) throws MalformedURLException, URISyntaxException {
|
||||||
Matcher m;
|
Matcher m;
|
||||||
|
|
||||||
URL sanitized = sanitizeURL(url);
|
URL sanitized = sanitizeURL(url);
|
||||||
|
Reference in New Issue
Block a user