mirror of
https://github.com/LamGC/ContentGrabbingJi.git
synced 2025-04-29 22:27:33 +00:00
[Fix] PreLoadDataAttributeComparator 修复获取PreLoadData抛出的异常信息未记录到日志的问题;
This commit is contained in:
parent
c64320ad78
commit
0e76cebc31
@ -3,6 +3,8 @@ package net.lamgc.cgj.bot.sort;
|
||||
import com.google.gson.JsonElement;
|
||||
import com.google.gson.JsonObject;
|
||||
import net.lamgc.cgj.bot.cache.CacheStoreCentral;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Comparator;
|
||||
@ -12,6 +14,8 @@ import java.util.Comparator;
|
||||
*/
|
||||
public class PreLoadDataAttributeComparator implements Comparator<JsonElement> {
|
||||
|
||||
private final static Logger log = LoggerFactory.getLogger(PreLoadDataAttributeComparator.class);
|
||||
|
||||
private final PreLoadDataAttribute attribute;
|
||||
|
||||
public PreLoadDataAttributeComparator(PreLoadDataAttribute attribute) {
|
||||
@ -47,7 +51,7 @@ public class PreLoadDataAttributeComparator implements Comparator<JsonElement> {
|
||||
illustPreLoadData2.get(attribute.attrName).getAsInt(),
|
||||
illustPreLoadData1.get(attribute.attrName).getAsInt());
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
log.error("获取预加载数据失败", e);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user