From 9feb8492aa01ff558caed3fbd84e1bb3b4359099 Mon Sep 17 00:00:00 2001 From: Dmitry Popov Date: Thu, 15 May 2025 23:15:07 +0200 Subject: [PATCH] fix(Core): Fixed connection EOL time refreshed every 2 minutes --- .../map/server/map_server_connections_impl.ex | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/lib/wanderer_app/map/server/map_server_connections_impl.ex b/lib/wanderer_app/map/server/map_server_connections_impl.ex index 7fb3a8b1..f6aed0b1 100644 --- a/lib/wanderer_app/map/server/map_server_connections_impl.ex +++ b/lib/wanderer_app/map/server/map_server_connections_impl.ex @@ -173,10 +173,12 @@ defmodule WandererApp.Map.Server.ConnectionsImpl do %{time_status: old_time_status}, %{id: connection_id, time_status: time_status} -> case time_status == @connection_time_status_eol do true -> - WandererApp.Cache.put( - "map_#{map_id}:conn_#{connection_id}:mark_eol_time", - DateTime.utc_now() - ) + if old_time_status != @connection_time_status_eol do + WandererApp.Cache.put( + "map_#{map_id}:conn_#{connection_id}:mark_eol_time", + DateTime.utc_now() + ) + end _ -> if old_time_status == @connection_time_status_eol do