--- a/src/rps_nickserv.erl Sat Mar 08 18:39:51 2014 +0900
+++ b/src/rps_nickserv.erl Sat Mar 08 21:55:29 2014 +0900
-export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]).
--export([start_link/0, nick/2, whois/1]).
+-export([start_link/0, nick/2, nick/3, whois/1, whois/2]).
gen_server:start_link({local, ?MODULE}, ?MODULE, [], []).
code_change(_OldVersion, State, _Extra) -> {ok, State}.
- gen_server:call(?MODULE, {nick, Who, Nickname}).
+ nick(?MODULE, Who, Nickname).
+nick(Pid, Who, Nickname) ->
+ gen_server:call(Pid, {nick, Who, Nickname}).
- gen_server:call(?MODULE, {whois, Who}).
+ gen_server:call(Pid, {whois, Who}).