File tree Expand file tree Collapse file tree 1 file changed +14
-6
lines changed
src/main/java/net/dv8tion/jda/internal Expand file tree Collapse file tree 1 file changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -394,14 +394,22 @@ else if (response.code == 401)
394394 }
395395 }.priority ();
396396
397- DataObject userResponse = login .complete ();
398- if (userResponse != null )
397+ try
399398 {
400- getEntityBuilder ().createSelfUser (userResponse );
401- return ;
399+ DataObject userResponse = login .complete ();
400+ if (userResponse != null )
401+ {
402+ getEntityBuilder ().createSelfUser (userResponse );
403+ return ;
404+ }
405+
406+ throw new InvalidTokenException ("The provided token is invalid!" );
407+ }
408+ catch (Throwable error )
409+ {
410+ shutdownNow ();
411+ throw error ;
402412 }
403- shutdownNow ();
404- throw new InvalidTokenException ("The provided token is invalid!" );
405413 }
406414
407415 public AuthorizationConfig getAuthorizationConfig ()
You can’t perform that action at this time.
0 commit comments