Skip to content

Commit 0401b87

Browse files
Merge pull request #11 from NeonAngelThreads/1.4.2
[+] Improved logging system. [!] Fixed the bug that could not run on Android (Termux). [!] Fixed the bug that the terminal reader could not initialize on Android.
2 parents 4c800d9 + 66f49ba commit 0401b87

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/main/java/org/angellock/impl/Start.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public static void main(String[] args) {
5757
try {
5858
Class.forName("com.mysql.cj.jdbc.Driver");
5959
} catch (ClassNotFoundException e) {
60-
log.warn(ConsoleTokens.colorizeText("&6MySQL driver not found in classpath, some plugins may not work properly."));
60+
log.warn(ConsoleTokens.colorizeText("[!] &6MySQL driver not found in classpath, some plugins may not work properly."));
6161
}
6262
optionParser.allowsUnrecognizedOptions();
6363

@@ -140,9 +140,11 @@ private static void getTerminal(RobotPlayer dolphinBot) {
140140
log.warn("To exit DolphinBot, press Ctrl + C again.");
141141
exit = true;
142142
}
143-
} catch (Throwable e) {
144-
e.printStackTrace();
145-
log.info(ConsoleTokens.colorizeText("&8Failed to send message: &7{}"), e.getMessage());
143+
} catch (Throwable ignored) {
144+
try {
145+
Thread.sleep(1000L);
146+
} catch (InterruptedException e) {
147+
}
146148
}
147149
}
148150
});

0 commit comments

Comments
 (0)