ChestShop-3/com/Acrobot/iConomyChestShop/Permission.java

20 lines
521 B
Java
Raw Normal View History

package com.Acrobot.iConomyChestShop;
import com.nijiko.permissions.PermissionHandler;
import org.bukkit.entity.Player;
/**
* @author Acrobot
*/
public class Permission {
public static PermissionHandler permissions;
public static boolean has(Player player, String permission) {
if (permissions != null) {
return permissions.has(player, permission);
} else {
return !permission.contains("exclude") && (!permission.contains("admin") || player.isOp());
}
}
}