anchor.diff:                      end
               end;
           _ ->
  -            log:debug("The message above did not match any clause.")
  +            []
       end,
       {noreply, State}.
  +
   
   code_change(_OldVsn, State, _Extra) ->
       {ok, State}.
   
  +
   terminate(Reason, _State) ->
       {shutdown, Reason}.
  
positive.code:     case Data of
          {ping, Server} ->
              send_data(self(), {ping, Server});
          {privmsg, {Nick, Msg}} ->
              channel:receive_message(channel_sup:get_channel(State#state.channel_sup, Nick), {privmsg_addressed, Msg});
          {privmsg, {Channel, Msg}} ->
              case channel_sup:get_channel(State#state.channel_sup, Channel) of
                  error ->
  
negative.code: handle_call({get_channel, ChanName}, _From, State) ->
      {reply, channel_sup:get_channel(State#state.channel_sup, ChanName), State}.
  
  
  handle_cast({join_channel, ChanName}, State) ->
      log:info("joining ~p on ~p", [ChanName, State#state.server_name]),
      channel_sup:start_channel(State#state.channel_sup, {self(), ChanName}),
      {noreply, State};
  
  handle_cast({part_channel, ChanName}, State) ->
      channel_sup:kill_channel(State#state.channel_sup, ChanName),
      log:info("left ~p on ~p", [ChanName, State#state.server_name]),
      {noreply, State};
  
  handle_cast({set_nick, Nickname}, State) ->
      send_data(self(), {nick, Nickname}),
      {noreply, State#state{nick = Nickname}};
  
  %% handle sending private messages
  handle_cast({send, {privmsg, {Nick, {Target, Text}}}}, State = #state{nick = Nick}) ->
      log:debug("<< ~p", [{privmsg, {Target, Text}}]),
      gen_tcp:send(State#state.tcp_socket, irc:format(privmsg, {Target, Text}) ++ "\r\n"),
      {noreply, State};
  
  handle_cast({send, {Type, Params}}, State) ->
      log:debug("<< ~p", [{Type, Params}]),
      gen_tcp:send(State#state.tcp_socket, irc:format(Type, Params) ++ "\r\n"),
      {noreply, State}.
  
  
  handle_info({tcp, _Socket, List}, State) ->
      Data = irc:parse(re:replace(List, "(\r\n)*", "", [global, {return, list}])),
  