From 3af0fe3bee379491600c726932f34d08582e77d8 Mon Sep 17 00:00:00 2001 From: Alexander Meech Date: Tue, 6 Dec 2016 20:52:49 -0500 Subject: [PATCH] Add a check for punishment removal permission --- .../src/mineplex/core/punish/UI/RemovePunishmentButton.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/punish/UI/RemovePunishmentButton.java b/Plugins/Mineplex.Core/src/mineplex/core/punish/UI/RemovePunishmentButton.java index 8989c87ba..fb4e72cd9 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/punish/UI/RemovePunishmentButton.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/punish/UI/RemovePunishmentButton.java @@ -23,6 +23,9 @@ public class RemovePunishmentButton implements IButton @Override public void onClick(Player player, ClickType clickType) { - _punishPage.RemovePunishment(_punishment, _item); + if (_punishPage.canUnban(true)) + { + _punishPage.RemovePunishment(_punishment, _item); + } } }