public static String toChannel(String chan){
  if (chan == null) {
    return null;
  }
  if (!validateChannel(chan)) {
    return StringUtil.toLowerCase(chan);
  }
  if (!chan.startsWith("#")) {
    chan="#" + chan;
  }
  return StringUtil.toLowerCase(chan);
}

public static String toChannel ( String chan ) { if ( chan == null ) { return null ; } if ( ! validateChannel ( chan ) ) { return StringUtil . toLowerCase ( chan ) ; } if ( ! chan . startsWith ( "#" ) ) { chan = "#" + chan ; } return StringUtil . toLowerCase ( chan ) ; }
if this is a valid channel name , then it turns it into a channel ( which means adding the # in front if necessary ) . otherwise it just returns the input in all lowercase .
