Skip to content

Commit

Permalink
Minor improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
Sanduhr32 committed Jan 11, 2018
1 parent 37ebb67 commit 485033a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public void executeCommand(String invoke, String[] args, GuildMessageReceivedEve

User toKick = event.getMessage().getMentionedUsers().get(0);
if (toKick.equals(event.getAuthor()) &&
!event.getGuild().getMember(event.getAuthor()).canInteract(event.getGuild().getMember(toKick))) {
!event.getMember().canInteract(event.getGuild().getMember(toKick))) {
sendMsg(event, "You are not permitted to perform this action.");
return;
}
Expand All @@ -70,7 +70,7 @@ public void executeCommand(String invoke, String[] args, GuildMessageReceivedEve
sendSuccess(event.getMessage());
}
);
} catch (HierarchyException e) {
} catch (HierarchyException ignored) { // if we don't do anything with it and just catch it we should name it "ignored"
//e.printStackTrace();
sendMsg(event, "I can't kick that member because his roles are above or equals to mine.");
}
Expand Down

0 comments on commit 485033a

Please sign in to comment.