File tree 1 file changed +9
-3
lines changed
gateway/src/main/java/com/javadiscord/jdi/internal/gateway
1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -82,8 +82,9 @@ private void handleMessage(Buffer buffer) {
82
82
}
83
83
84
84
private void handleClose (Void unused ) {
85
- retryHandler .retry (
86
- () -> connectionMediator .getWebSocketManagerProxy ().start (connectionMediator ));
85
+ LOGGER .warn (
86
+ "The web socket connection to discord was closed. You will no longer receive"
87
+ + " gateway events." );
87
88
}
88
89
89
90
void handleClose (int status , String reason ) {
@@ -106,8 +107,13 @@ void handleClose(int status, String reason) {
106
107
"Discord has updated their API, please use the latest updates on"
107
108
+ " https://javadiscord.com/" );
108
109
break ;
110
+ case GatewayCloseEventCode .DISALLOWED_INTENTS :
111
+ LOGGER .error (
112
+ "You do not have all the required intents set on your bot. Visit"
113
+ + " https://discord.com/developers/applications/" );
114
+ break ;
109
115
default :
110
- LOGGER .error ("[{}] {}" , status , reason );
116
+ LOGGER .error ("Web socket close reason [{}] {}" , status , reason );
111
117
break ;
112
118
}
113
119
}
You can’t perform that action at this time.
0 commit comments