We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3bb7d97 commit a5ab2afCopy full SHA for a5ab2af
src/main/java/club/bytecode/the/jda/JDA.java
@@ -194,11 +194,7 @@ private static void onExit() {
194
*/
195
public static void waitForTasks() {
196
while (jobCount.get() > 0) {
197
- try {
198
- Thread.sleep(10L);
199
- } catch (InterruptedException e) {
200
- e.printStackTrace();
201
- }
+ GuiUtils.sleep(10L);
202
}
203
204
src/main/java/club/bytecode/the/jda/util/GuiUtils.java
@@ -48,4 +48,12 @@ public static void setLookAndFeel() {
48
49
50
51
+
52
+ public static void sleep(long millis) {
53
+ try {
54
+ Thread.sleep(millis);
55
+ } catch(InterruptedException e) {
56
+ e.printStackTrace();
57
+ }
58
59
0 commit comments