From aa520bb36e964e7cace7ed655f040bc9d3ead9b6 Mon Sep 17 00:00:00 2001 From: Tobias Ottenweller Date: Wed, 16 May 2012 23:16:58 +0200 Subject: [PATCH] refactoring of command info --- src/org/mcteam/ancientgates/commands/CommandInfo.java | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/org/mcteam/ancientgates/commands/CommandInfo.java b/src/org/mcteam/ancientgates/commands/CommandInfo.java index 9a8fb75..1a44cdd 100644 --- a/src/org/mcteam/ancientgates/commands/CommandInfo.java +++ b/src/org/mcteam/ancientgates/commands/CommandInfo.java @@ -14,6 +14,8 @@ public class CommandInfo extends BaseCommand requiredParameters.add("id"); helpDescription = "Prints information about a gate"; + + requiredPermission = Plugin.permissionInfo; } @@ -45,11 +47,5 @@ public class CommandInfo extends BaseCommand else sendMessage(ChatColor.GREEN + "this gate has no 'to' location"); } - - - @Override - public boolean hasPermission(CommandSender sender) - { - return sender.hasPermission(permissionInfo) || sender.hasPermission(permissionManage); - } + }