Skip to content

Commit

Permalink
Merge pull request #121 from Simba98/forge
Browse files Browse the repository at this point in the history
Forge Cherry-Pick Fixes
  • Loading branch information
cnlimiter authored Dec 7, 2023
2 parents 71fb345 + 42f60e9 commit d87379b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,11 @@ public static String get(String key, Object... args) {
}

public static String get(String key) {
return translations.get(key);
String translation = translations.get(key);
if (translation != null) {
return translation;
} else {
return key;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ private static boolean isVar(String msg) {
public static String varParse(CustomCmd customCmd, String cmd) {
String returnCmd = "";
if (isVar(cmd)) {//存在变量
val replaceContent = customCmd.getCmdContent().split("%")[0].replaceAll(" ", "");
val replaceContent = customCmd.getCmdContent().split("%")[0].trim();
returnCmd = cmd.replace(customCmd.getCmdAlies(), replaceContent);//返回q群指令
} else returnCmd = customCmd.getCmdContent();//返回普通自定义命令指令
return returnCmd;
Expand Down

0 comments on commit d87379b

Please sign in to comment.