From fd71e871e643454c2e02e4252f3478b1993f31d0 Mon Sep 17 00:00:00 2001 From: Tristan Cormier Date: Wed, 8 Oct 2025 10:51:39 -0400 Subject: [PATCH] chore(ClientServices): add assertion in Connection method --- src/client/ClientServices.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/client/ClientServices.cpp b/src/client/ClientServices.cpp index 15590d9..d32c989 100644 --- a/src/client/ClientServices.cpp +++ b/src/client/ClientServices.cpp @@ -155,8 +155,7 @@ void ClientServices::ConnectToSelectedServer() { } ClientConnection* ClientServices::Connection() { - // TODO assertion? - + STORM_ASSERT(ClientServices::s_currentConnection); return ClientServices::s_currentConnection; } @@ -390,9 +389,7 @@ void ClientServices::SetCharacterInfo(const CHARACTER_INFO* info) { void ClientServices::SetMessageHandler(NETMESSAGE msgId, MESSAGE_HANDLER handler, void* param) { STORM_ASSERT(handler); - STORM_ASSERT(ClientServices::s_currentConnection); - - ClientServices::s_currentConnection->SetMessageHandler(msgId, handler, param); + ClientServices::Connection()->SetMessageHandler(msgId, handler, param); } int32_t ClientServices::SetSelectedRealmInfo(int32_t a1) {