title: Getting Internal Error in Subcommand Bukkit
body: <p>I've been facing a problem lately with bukkit coding. When I launch the plugin and just type /akitz   <strong>command label or name</strong> it pops up with an Internal Error but when I type /akitz {subcommand} it works fine! everything here basically works fine but just the /akitz   &lt;-- alone when i type it, an error pops up!   here's the code:</p>
  <pre><code>package me.frostgamersa;
  
  import org.bukkit.Material;
  import org.bukkit.command.Command;
  import org.bukkit.command.CommandSender;
  import org.bukkit.entity.Player;
  import org.bukkit.inventory.ItemStack;
  import org.bukkit.plugin.java.JavaPlugin;
  
  public class Main extends JavaPlugin {
  @Override
  public void onEnable() {
  
  }
  
  @Override
  public void onDisable() {
  
  }
  
  @Override
  public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) {
      if (label.equalsIgnoreCase(&quot;akitz&quot;)) {
          Player player = (Player) sender;
  
          if (args.length == 0 || args.length &lt; 2) {
              player.sendMessage(&quot;§cIncorrect Arguments&quot;);
  
              if (args[0].equalsIgnoreCase(&quot;legend&quot;)) {
                  player.sendMessage(&quot;§bYou have been Granted §3Legend §bKit!&quot;);
                  CustomItems.givela(player);
                  CustomItems.givels(player);
                  player.getInventory().addItem(new ItemStack(Material.GOLDEN_APPLE, 64));
                  return true;
              }
              if (args[0].equalsIgnoreCase(&quot;god&quot;)) {
                  player.sendMessage(&quot;§bYou have been Granted §3God §bKit!&quot;);
                  CustomItems.givega(player);
                  CustomItems.givegs(player);
                  player.getInventory().addItem(new ItemStack(Material.GOLDEN_APPLE, 64));
                  return true;
              } else {
                  player.sendMessage(&quot;§cIncorrect Arguments!&quot;);
                  return true;
              }
          }
  </code></pre>