From 40730c4fa73d403cf7284a76d9b26f7ec662afa4 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 2 Sep 2015 03:12:14 +0300 Subject: Remove mNetwork field from MessageHandlers --- src/net/eathena/loginhandler.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/net/eathena/loginhandler.cpp') diff --git a/src/net/eathena/loginhandler.cpp b/src/net/eathena/loginhandler.cpp index cca2a90eb..9376d24b5 100644 --- a/src/net/eathena/loginhandler.cpp +++ b/src/net/eathena/loginhandler.cpp @@ -105,10 +105,10 @@ void LoginHandler::handleMessage(Net::MessageIn &msg) void LoginHandler::connect() { - if (!mNetwork) + if (!Network::mInstance) return; - mNetwork->connect(mServer); + Network::mInstance->connect(mServer); if (serverFeatures->haveServerVersion()) { sendVersion(); @@ -122,16 +122,16 @@ void LoginHandler::connect() bool LoginHandler::isConnected() const { - if (!mNetwork) + if (!Network::mInstance) return false; - return mNetwork->isConnected(); + return Network::mInstance->isConnected(); } void LoginHandler::disconnect() { - if (mNetwork && mNetwork->getServer() == mServer) - mNetwork->disconnect(); + if (Network::mInstance && Network::mInstance->getServer() == mServer) + Network::mInstance->disconnect(); } void LoginHandler::changePassword(const std::string &restrict oldPassword, -- cgit v1.2.3-70-g09d2