gt: 		if (channel == null){
context: package com.mcnsa.chat.plugin.components;
  
  import java.text.SimpleDateFormat;
  import java.util.ArrayList;
  import java.util.Date;
  import java.util.HashMap;
  import java.util.Map;
  import java.util.Map.Entry;
  
  import org.bukkit.Bukkit;
  import org.bukkit.command.CommandSender;
  
  import com.mcnsa.chat.plugin.MCNSAChat;
  import com.mcnsa.chat.plugin.annotations.Command;
  import com.mcnsa.chat.plugin.annotations.ComponentInfo;
  import com.mcnsa.chat.plugin.managers.BotManager;
  import com.mcnsa.chat.plugin.managers.ChannelManager;
  import com.mcnsa.chat.plugin.managers.Permissions;
  import com.mcnsa.chat.plugin.managers.PlayerManager;
  import com.mcnsa.chat.plugin.utils.Colours;
  import com.mcnsa.chat.plugin.utils.MessageSender;
  import com.mcnsa.chat.type.ChatChannel;
  import com.mcnsa.chat.type.ChatPlayer;
  
  @ComponentInfo(friendlyName = "Admin",
  description = "Admin commands",
  permsSettingsPrefix = "admin")
  public class AdminCommands {
  	
  	@Command(
  			command = "cto",
  			description = "Player chat timeout",
  			permissions = {"timeout"}
  			)
  	public static boolean ctoList(CommandSender sender) {
  		//Function lists players in timeout
  		
  		//Start output arraylist
  		Map<String, Long> output = new HashMap<String, Long>();
  		//Get players in timeout
  		for (ChatPlayer player: PlayerManager.players) {
  			if (player.modes.get("MUTE"))
  				if (!output.containsKey(player.name))
  					output.put(player.name, player.timeoutTill);
  		}
  		
  		if (output.isEmpty()) {
  			MessageSender.send("&6There is no-one currently in timeout", sender.getName());
  			return true;
  		}
  		
  		//Start the output
  		MessageSender.send("&6Players in timeout", sender.getName());
  				
  		//Loop through players in timeout
  		for (Entry<String, Long> entry : output.entrySet()) {
  		    String player = entry.getKey();
  		    Date timeoutTime = new Date(entry.getValue());
  		    SimpleDateFormat df = new SimpleDateFormat("HH:mm:ss dd.MMM");
  		    MessageSender.send("&c"+player+" Until "+df.format(timeoutTime), sender.getName());
  		}
  		
  		return true;
  	}
  	
  	@Command(
  			command = "cto",
  			description = "Player chat timeout",
  			arguments = {"Player"},
  			permissions = {"timeout"}
  			)
  	public static boolean ctoRemove(CommandSender sender, String target) {
  		
  		ArrayList<ChatPlayer> targetPlayers = PlayerManager.playerSearch(target);
  		if (targetPlayers.isEmpty()) {
  			MessageSender.send("&cCould not find player", sender.getName());
  			return true;
  		}
  		
  		ChatPlayer targetPlayer = targetPlayers.get(0);
  		
  		if (!targetPlayer.modes.get("MUTE")) {
  			MessageSender.send("&cThat player is not in timeout", sender.getName());
  			return true;
  		}
  
  		PlayerManager.unmutePlayer(targetPlayer.name);
  		MessageSender.send("&6"+targetPlayer.name+" has been removed from timeout", sender.getName());
  		
  		return true;
  	}
  	
  	@Command(
  			command = "cto",
  			description = "Player chat timeout",
  			arguments = {"Player", "time", "reason"},
  			permissions = {"timeout"}
  			)
  	public static boolean ctoadd(CommandSender sender, String target, String time, String... reason) {
  		ArrayList<ChatPlayer> targetPlayers = PlayerManager.playerSearch(target);
  		if (targetPlayers.isEmpty()) {
  			MessageSender.send("&cCould not find player", sender.getName());
  			return true;
  		}
  		ChatPlayer targetPlayer = targetPlayers.get(0);
  		
  		if (targetPlayer.modes.get("MUTE")) {
  			MessageSender.send("&cThat player already in timeout", sender.getName());
  			return true;
  		}
  		//Build reason
  		StringBuffer sb = new StringBuffer();
  		for (String reasonPart: reason) {
  			if (sb.length() < 1)
  				sb.append(reasonPart);
  			else 
  				sb.append(" "+reasonPart);
  		}
  		//Mute and notify
  		PlayerManager.mutePlayer(targetPlayer.name, time, sb.toString());
  		
  		//Start timer
  		final String finalPlayerName = targetPlayer.name;
  		long timeleft = Integer.valueOf(time) * 1200;
  		Bukkit.getScheduler().scheduleSyncDelayedTask(MCNSAChat.plugin, new Runnable() {
  			public void run() {
  					if (PlayerManager.getPlayer(finalPlayerName, MCNSAChat.shortCode) != null && PlayerManager.getPlayer(finalPlayerName, MCNSAChat.shortCode).modes.get("MUTE")){
  						PlayerManager.unmutePlayer(finalPlayerName);
  					}
  				}
  		}, timeleft);
  		return true;
  	}
  	
  	@Command(
  			command = "cregister",
  			description = "Register a channel with the channel manager",
  			permissions = {"register"},
  			arguments = {"Channel"},
  			playerOnly = true
  			)
  	public static boolean registerChannel(CommandSender sender, String channel) {
  		//Function registers a channel with the channel manager
  		channel = channel.substring(0, 1).toUpperCase() + channel.substring(1);
  		//Check to make sure the channel isn't already registered.
  		if (ChannelManager.getChannel(channel) != null) {
  			MessageSender.send("&cChannel is already registered.", sender.getName());
  			return true;
  		}
  		
  		//Create the channel
  		ChatChannel Channel = new ChatChannel(channel);
  		//make the channel persistent
  		Channel.modes.put("PERSIST", true);
  		
  		//Let the sender know that its created
  		MessageSender.send("&6Channel "+channel+" registered", sender.getName());
  		
  		//Add to channel Manager
  		ChannelManager.channels.add(Channel);
  
  		return true;
  	}
  	
  	@Command(
  			command = "cmode",
  			description = "Add a mode to the channel your in: Rave, Boring, or Local",
  			arguments = {"action","Mode"},
  			permissions = {"mode"},
  			playerOnly = true
  			)
  	public static boolean addMode(CommandSender sender, String action, String mode) {
  		//Function adds modes to the channel
  		//Get the channel
  		ChatChannel channel = ChannelManager.getChannel(PlayerManager.getPlayer(sender.getName(), MCNSAChat.shortCode).channel);
  		if (channel == null) {
  			MessageSender.send("&cChannel is not registered. Please register first by /cregister <channel>", sender.getName());
  			return true;
  		}
  		if (action.equalsIgnoreCase("add")) {
  			if (mode.equalsIgnoreCase("rave")) {
  				channel.modes.put("RAVE", true);
  				MessageSender.send("&6Rave mode activated!", sender.getName());
  			}
  			else if (mode.equalsIgnoreCase("boring")) {
  				channel.modes.put("BORING", true);
  				MessageSender.send("&6Boring mode activated!", sender.getName());
  			}
  			else if (mode.equalsIgnoreCase("local")) {
  				channel.modes.put("LOCAL", true);
  				MessageSender.send("&6Local mode activated!", sender.getName());
  			}
  		}
  		else if (action.equalsIgnoreCase("del")){
  			if (mode.equalsIgnoreCase("rave")) {
  				channel.modes.put("RAVE", false);
  				MessageSender.send("&6Rave mode deactivated!", sender.getName());
  			}
  			else if (mode.equalsIgnoreCase("boring")) {
  				channel.modes.put("BORING", false);
  				MessageSender.send("&6Boring mode deactivated!", sender.getName());
  			}
  			else if (mode.equalsIgnoreCase("local")) {
  				channel.modes.put("LOCAL", false);
  				MessageSender.send("&6Local mode deactivated!", sender.getName());
  			}
  		}
  		else {
  			MessageSender.send("&cUsage: /cmode [add|del] [rave|boring|mute|local]", sender.getName());
  		}
  		return true;
  	}
  
  	@Command(
  			command = "cedit",
  			arguments = {"setting", "variable"},
  			description = "Set the alias and read/write permissions fo the channel your in",
  			permissions = {"modify"},
  			playerOnly = true
  			)
  	public static boolean chanmodify(CommandSender sender,String setting, String... var) {
  		//Get channel
  		ChatChannel channel = ChannelManager.getChannel(PlayerManager.getPlayer(sender.getName()).channel);
  		if (var[0] == null)
  			var [0] = "";
  