Skip to content

Commit

Permalink
Fix /bsc reload perms
Browse files Browse the repository at this point in the history
  • Loading branch information
mnewt00 committed May 3, 2021
1 parent 62ad118 commit 0491250
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public BetterStaffChatCommand() {

@Override
public void execute(CommandSender sender, String[] args) {
if (args.length == 1 && args[0].equalsIgnoreCase("reload")) {
if (args.length == 1 && args[0].equalsIgnoreCase("reload") && sender.hasPermission("betterstaffchat.reload")) {
boolean reload = BetterStaffChatBungeeCord.getInstance().reloadConfig(sender);
if (!reload && BetterStaffChatBungeeCord.getInstance().getConfig().getBoolean("discord.bot.enabled")) {
((JDAImplementation) BetterStaffChatBungeeCord.getInstance().getJda()).asJda().getPresence().setActivity(Activity.of(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public BetterStaffChatCommand() {

@Override
public boolean execute(CommandSender sender, String commandLabel, String[] args) {
if (args.length == 1 && args[0].equalsIgnoreCase("reload")) {
if (args.length == 1 && args[0].equalsIgnoreCase("reload") && sender.hasPermission("betterstaffchat.reload")) {
boolean reload = BetterStaffChatSpigot.getInstance().reloadConfig(sender);
if (!reload && BetterStaffChatSpigot.getInstance().getConfig().getBoolean("discord.bot.enabled")) {
((JDAImplementation) BetterStaffChatSpigot.getInstance().getJda()).asJda().getPresence().setActivity(Activity.of(
Expand Down

0 comments on commit 0491250

Please sign in to comment.