Skip to content

Commit

Permalink
Reset heartbeat_ack on WS reconnect.
Browse files Browse the repository at this point in the history
  • Loading branch information
Aely0 authored and Kraigie committed Aug 14, 2019
1 parent d215d4c commit d424c47
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/nostrum/shard/session.ex
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ defmodule Nostrum.Shard.Session do
stream = :gun.ws_upgrade(worker, @gateway_qs)
await_ws_upgrade(worker, stream)
Logger.warn("Reconnected after connection broke")
{:noreply, state}
{:noreply, %{state | heartbeat_ack: true}}
end

def handle_cast({:status_update, payload}, state) do
Expand Down

0 comments on commit d424c47

Please # to comment.