summaryrefslogtreecommitdiff
path: root/lib/irc/puppet_connection.ex
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--lib/irc/puppet_connection.ex4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/irc/puppet_connection.ex b/lib/irc/puppet_connection.ex
index 68f1425..8c9b218 100644
--- a/lib/irc/puppet_connection.ex
+++ b/lib/irc/puppet_connection.ex
@@ -52,6 +52,10 @@ defmodule IRC.PuppetConnection do
GenServer.cast(pid, {:send_message, channel, text})
end
+ def start(account = %IRC.Account{}, connection = %IRC.Connection{}) do
+ IRC.PuppetConnection.Supervisor.start_child(account, connection)
+ end
+
def start_link(account_id, connection_id) do
GenServer.start_link(__MODULE__, [account_id, connection_id], name: name(account_id, connection_id))
end