Fix BongaCams online check
This commit is contained in:
parent
0f125f6e63
commit
4a595da355
|
@ -55,7 +55,7 @@ public class BongaCamsModel extends AbstractModel {
|
|||
@Override
|
||||
public boolean isOnline(boolean ignoreCache) throws IOException, ExecutionException, InterruptedException {
|
||||
if (ignoreCache) {
|
||||
String url = "https://en.bongacams.com/" + URLEncoder.encode(getDisplayName(), StandardCharsets.UTF_8.name());
|
||||
String url = "https://en.bongacams.com/" + URLEncoder.encode(getName(), StandardCharsets.UTF_8.name());
|
||||
Request req = new Request.Builder().url(url)
|
||||
.header(USER_AGENT, Config.getInstance().getSettings().httpUserAgent)
|
||||
.header(ACCEPT, "*")
|
||||
|
@ -77,6 +77,7 @@ public class BongaCamsModel extends AbstractModel {
|
|||
online = false;
|
||||
}
|
||||
} catch (HtmlParserException e) {
|
||||
LOG.warn("Online check didn't work", e);
|
||||
online = false;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue