summaryrefslogtreecommitdiff
path: root/lib/web/live/chat_live.ex
diff options
context:
space:
mode:
authorJordan Bracco <href@random.sh>2022-12-20 02:47:33 +0000
committerJordan Bracco <href@random.sh>2022-12-20 19:29:41 +0100
commit2127553ad058bfa688feb73097e604a8fb5a1899 (patch)
tree3246c31aef0f6c3a110376de21265a6f5d02c597 /lib/web/live/chat_live.ex
parentIRC.PubSub -> Nola.PubSub, refs T77 (diff)
Rename IRC.Account to Nola.Account, refs T77
Diffstat (limited to 'lib/web/live/chat_live.ex')
-rw-r--r--lib/web/live/chat_live.ex6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/web/live/chat_live.ex b/lib/web/live/chat_live.ex
index 88afa0b..0513cc2 100644
--- a/lib/web/live/chat_live.ex
+++ b/lib/web/live/chat_live.ex
@@ -6,8 +6,8 @@ defmodule NolaWeb.ChatLive do
def mount(%{"network" => network, "chan" => chan}, %{"account" => account_id}, socket) do
chan = NolaWeb.reformat_chan(chan)
connection = IRC.Connection.get_network(network, chan)
- account = IRC.Account.get(account_id)
- membership = IRC.Membership.of_account(IRC.Account.get("DRgpD4fLf8PDJMLp8Dtb"))
+ account = Nola.Account.get(account_id)
+ membership = IRC.Membership.of_account(Nola.Account.get("DRgpD4fLf8PDJMLp8Dtb"))
if account && connection && Enum.member?(membership, {connection.network, chan}) do
{:ok, _} = Registry.register(Nola.PubSub, "#{connection.network}:events", plugin: __MODULE__)
for t <- ["messages", "triggers", "outputs", "events"] do
@@ -47,7 +47,7 @@ defmodule NolaWeb.ChatLive do
end
def handle_event("send", %{"message" => %{"text" => text}}, socket) do
- account = IRC.Account.get(socket.assigns.account_id)
+ account = Nola.Account.get(socket.assigns.account_id)
IRC.send_message_as(account, socket.assigns.network, socket.assigns.channel, text, true)
{:noreply, assign(socket, :counter, socket.assigns.counter + 1)}
end