diff --git a/gradle.properties b/gradle.properties
index 0e8762b..26864bd 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -1,6 +1,6 @@
## Core
-VERSION = 0.4.3.4
+VERSION = 0.4.3.5
# dependencies
diff --git a/src/main/java/cc/sukazyo/cono/morny/GradleProjectConfigures.java b/src/main/java/cc/sukazyo/cono/morny/GradleProjectConfigures.java
index a927157..1b20bb4 100644
--- a/src/main/java/cc/sukazyo/cono/morny/GradleProjectConfigures.java
+++ b/src/main/java/cc/sukazyo/cono/morny/GradleProjectConfigures.java
@@ -4,6 +4,6 @@ package cc.sukazyo.cono.morny;
* the final field that will be updated by gradle automatically.
*/
public class GradleProjectConfigures {
- public static final String VERSION = "0.4.3.4";
- public static final long COMPILE_TIMESTAMP = 1642273245554L;
+ public static final String VERSION = "0.4.3.5";
+ public static final long COMPILE_TIMESTAMP = 1642297552612L;
}
diff --git a/src/main/java/cc/sukazyo/cono/morny/bot/event/on_commands/Nbnhhsh.java b/src/main/java/cc/sukazyo/cono/morny/bot/event/on_commands/Nbnhhsh.java
index 8cf4649..7dd130e 100644
--- a/src/main/java/cc/sukazyo/cono/morny/bot/event/on_commands/Nbnhhsh.java
+++ b/src/main/java/cc/sukazyo/cono/morny/bot/event/on_commands/Nbnhhsh.java
@@ -28,11 +28,20 @@ public class Nbnhhsh {
StringBuilder message = new StringBuilder("## Result of nbnhhsh query :");
for (NbnhhshQuery.Word word : response.words) {
- if (word.trans == null) continue;
+ if (word.trans != null && word.trans.length == 0) word.trans = null;
+ if (word.inputting != null && word.inputting.length == 0) word.inputting = null;
+ if (word.trans == null && word.inputting == null) continue;
message.append("\n\n[[ ").append(escapeHtml(word.name)).append(" ]]");
- for (String trans : word.trans) {
+ if (word.trans != null) for (String trans : word.trans) {
message.append("\n* ").append(escapeHtml(trans)).append("");
}
+ if (word.inputting != null) {
+ if (word.trans != null) message.append("\n");
+ message.append(" maybe:");
+ for (String trans : word.inputting) {
+ message.append("\n` ").append(escapeHtml(trans)).append("");
+ }
+ }
}
MornyCoeur.extra().exec(new SendMessage(
diff --git a/src/main/java/cc/sukazyo/cono/morny/data/NbnhhshQuery.java b/src/main/java/cc/sukazyo/cono/morny/data/NbnhhshQuery.java
index 27c5932..90119aa 100644
--- a/src/main/java/cc/sukazyo/cono/morny/data/NbnhhshQuery.java
+++ b/src/main/java/cc/sukazyo/cono/morny/data/NbnhhshQuery.java
@@ -16,6 +16,7 @@ public class NbnhhshQuery {
public static class Word {
public String name;
public String[] trans;
+ public String[] inputting;
}
public static class GuessResult {