Fixed timeout delay after ratelimit

This commit is contained in:
Norbi Peti 2016-12-22 20:57:13 +01:00
parent aeee423c5a
commit 3c16795964

View file

@ -111,7 +111,8 @@ public class MCChatListener implements Listener, IListener<MessageReceivedEvent>
Thread.sleep(100); Thread.sleep(100);
break; break;
} catch (RateLimitException e) { } catch (RateLimitException e) {
Thread.sleep(e.getRetryDelay()); if (e.getRetryDelay() > 0)
Thread.sleep(e.getRetryDelay());
} }
} }
} catch (Exception e) { } catch (Exception e) {