mirror of
https://github.com/LamGC/ContentGrabbingJi.git
synced 2025-04-30 06:37:36 +00:00
[Fix] BotGlobal 修复BotGlobal初始化失败的问题;
This commit is contained in:
parent
4589624b9b
commit
b39a82b936
@ -14,6 +14,8 @@ import java.net.URL;
|
|||||||
|
|
||||||
public final class BotGlobal {
|
public final class BotGlobal {
|
||||||
|
|
||||||
|
private final static Logger log = LoggerFactory.getLogger(BotGlobal.class);
|
||||||
|
|
||||||
private final static BotGlobal instance = new BotGlobal();
|
private final static BotGlobal instance = new BotGlobal();
|
||||||
|
|
||||||
public static BotGlobal getGlobal() {
|
public static BotGlobal getGlobal() {
|
||||||
@ -23,8 +25,6 @@ public final class BotGlobal {
|
|||||||
return instance;
|
return instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
private final static Logger log = LoggerFactory.getLogger(BotGlobal.class);
|
|
||||||
|
|
||||||
private final URI redisUri;
|
private final URI redisUri;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -53,7 +53,7 @@ public final class BotGlobal {
|
|||||||
try {
|
try {
|
||||||
URL proxyUrl = new URL(proxyAddress);
|
URL proxyUrl = new URL(proxyAddress);
|
||||||
temp = new HttpHost(proxyUrl.getHost(), proxyUrl.getPort());
|
temp = new HttpHost(proxyUrl.getHost(), proxyUrl.getPort());
|
||||||
log.info("已启用Http协议代理:{}", temp.toHostString());
|
log.info("已启用代理:{}", temp.toHostString());
|
||||||
} catch (MalformedURLException e) {
|
} catch (MalformedURLException e) {
|
||||||
log.error("Proxy地址解析失败, 代理将不会启用.", e);
|
log.error("Proxy地址解析失败, 代理将不会启用.", e);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user