1
0
Fork 0
forked from mirrors/akkoma

websocket handler: Do not log client ping frames as errors

This commit is contained in:
rinpatch 2020-09-10 13:47:53 +03:00
parent 9d20d29a79
commit cb06e98da2

View file

@ -64,7 +64,9 @@ def websocket_handle(:pong, state) do
{:ok, %{state | timer: timer()}} {:ok, %{state | timer: timer()}}
end end
# We never receive messages. # We only receive pings for now
def websocket_handle(:ping, state), do: {:ok, state}
def websocket_handle(frame, state) do def websocket_handle(frame, state) do
Logger.error("#{__MODULE__} received frame: #{inspect(frame)}") Logger.error("#{__MODULE__} received frame: #{inspect(frame)}")
{:ok, state} {:ok, state}