mirror of
https://github.com/LamGC/ContentGrabbingJi.git
synced 2025-04-30 06:37:36 +00:00
[Fix] BotCommandProcess 修复部分指令无法使用群组配置的问题;
This commit is contained in:
parent
181d60285b
commit
597aac4e95
@ -245,7 +245,7 @@ public class BotCommandProcess {
|
|||||||
String itemLimitPropertyKey = "ranking.itemCountLimit";
|
String itemLimitPropertyKey = "ranking.itemCountLimit";
|
||||||
try {
|
try {
|
||||||
itemLimit = Integer.parseInt(SettingProperties
|
itemLimit = Integer.parseInt(SettingProperties
|
||||||
.getProperty(SettingProperties.GLOBAL, itemLimitPropertyKey, "10"));
|
.getProperty(fromGroup, itemLimitPropertyKey, "10"));
|
||||||
} catch(NumberFormatException e) {
|
} catch(NumberFormatException e) {
|
||||||
log.warn("配置项 {} 的参数值格式有误!", itemLimitPropertyKey);
|
log.warn("配置项 {} 的参数值格式有误!", itemLimitPropertyKey);
|
||||||
}
|
}
|
||||||
@ -254,7 +254,7 @@ public class BotCommandProcess {
|
|||||||
String imageLimitPropertyKey = "ranking.imageCountLimit";
|
String imageLimitPropertyKey = "ranking.imageCountLimit";
|
||||||
try {
|
try {
|
||||||
imageLimit = Integer.parseInt(
|
imageLimit = Integer.parseInt(
|
||||||
SettingProperties.getProperty(SettingProperties.GLOBAL, imageLimitPropertyKey, "3"));
|
SettingProperties.getProperty(fromGroup, imageLimitPropertyKey, "3"));
|
||||||
} catch(NumberFormatException e) {
|
} catch(NumberFormatException e) {
|
||||||
log.warn("配置项 {} 的参数值格式有误!", imageLimitPropertyKey);
|
log.warn("配置项 {} 的参数值格式有误!", imageLimitPropertyKey);
|
||||||
}
|
}
|
||||||
@ -408,7 +408,7 @@ public class BotCommandProcess {
|
|||||||
int limit = 8;
|
int limit = 8;
|
||||||
try {
|
try {
|
||||||
limit = Integer.parseInt(SettingProperties.
|
limit = Integer.parseInt(SettingProperties.
|
||||||
getProperty(SettingProperties.GLOBAL, "search.itemCountLimit", "8"));
|
getProperty(fromGroup, "search.itemCountLimit", "8"));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.warn("参数转换异常!将使用默认值(" + limit + ")", e);
|
log.warn("参数转换异常!将使用默认值(" + limit + ")", e);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user