From 29d5ccf75148fef5ec490e7cdbe1e177c35deaf5 Mon Sep 17 00:00:00 2001 From: Olivia Date: Sun, 13 Sep 2020 17:23:50 -0700 Subject: [PATCH] Fix /lightning ignoring essentials.lightning.others (#3671) --- .../com/earth2me/essentials/commands/Commandlightning.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandlightning.java b/Essentials/src/com/earth2me/essentials/commands/Commandlightning.java index 391446f82..9b99ea166 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandlightning.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandlightning.java @@ -19,8 +19,8 @@ public class Commandlightning extends EssentialsLoopCommand { @Override public void run(final Server server, final CommandSource sender, final String commandLabel, final String[] args) throws Exception { - if (args.length == 0) { - if (sender.isPlayer() || !sender.isAuthorized("essentials.lightning.others", ess)) { + if (args.length == 0 || !sender.isAuthorized("essentials.lightning.others", ess)) { + if (sender.isPlayer()) { sender.getPlayer().getWorld().strikeLightning(sender.getPlayer().getTargetBlock(null, 600).getLocation()); return; }