Commit 67afd024 authored by lain's avatar lain

Streamer: Make it less chatty.

parent 810cf861
...@@ -74,7 +74,6 @@ def handle_cast(%{action: :add, topic: topic, socket: socket}, sockets) do ...@@ -74,7 +74,6 @@ def handle_cast(%{action: :add, topic: topic, socket: socket}, sockets) do
sockets_for_topic = Enum.uniq([socket | sockets_for_topic]) sockets_for_topic = Enum.uniq([socket | sockets_for_topic])
sockets = Map.put(sockets, topic, sockets_for_topic) sockets = Map.put(sockets, topic, sockets_for_topic)
Logger.debug("Got new conn for #{topic}") Logger.debug("Got new conn for #{topic}")
IO.inspect(sockets)
{:noreply, sockets} {:noreply, sockets}
end end
...@@ -84,12 +83,11 @@ def handle_cast(%{action: :remove, topic: topic, socket: socket}, sockets) do ...@@ -84,12 +83,11 @@ def handle_cast(%{action: :remove, topic: topic, socket: socket}, sockets) do
sockets_for_topic = List.delete(sockets_for_topic, socket) sockets_for_topic = List.delete(sockets_for_topic, socket)
sockets = Map.put(sockets, topic, sockets_for_topic) sockets = Map.put(sockets, topic, sockets_for_topic)
Logger.debug("Removed conn for #{topic}") Logger.debug("Removed conn for #{topic}")
IO.inspect(sockets)
{:noreply, sockets} {:noreply, sockets}
end end
def handle_cast(m, state) do def handle_cast(m, state) do
IO.inspect("Unknown: #{inspect(m)}, #{inspect(state)}") Logger.info("Unknown: #{inspect(m)}, #{inspect(state)}")
{:noreply, state} {:noreply, state}
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment