diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-02-08 23:02:06 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-02-08 23:02:06 +0300 |
commit | 7e66a4606bb15d98197f71245fe191d03152ee5f (patch) | |
tree | 825022571cfb55d70f1ca3c142f79db3758fb72b /src/net/eathena/chathandler.cpp | |
parent | a61ac4664d55cddb18d2d861e76629bd07676129 (diff) | |
download | manaplus-7e66a4606bb15d98197f71245fe191d03152ee5f.tar.gz manaplus-7e66a4606bb15d98197f71245fe191d03152ee5f.tar.bz2 manaplus-7e66a4606bb15d98197f71245fe191d03152ee5f.tar.xz manaplus-7e66a4606bb15d98197f71245fe191d03152ee5f.zip |
Improve some empty string checks.
Diffstat (limited to 'src/net/eathena/chathandler.cpp')
-rw-r--r-- | src/net/eathena/chathandler.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/net/eathena/chathandler.cpp b/src/net/eathena/chathandler.cpp index 353a82b0e..6efbb7864 100644 --- a/src/net/eathena/chathandler.cpp +++ b/src/net/eathena/chathandler.cpp @@ -99,7 +99,7 @@ void ChatHandler::sendRaw(const std::string &args) const std::string str; MessageOut *outMsg = nullptr; - if (line == "") + if (line.empty()) return; size_t pos = line.find(" "); @@ -129,7 +129,7 @@ void ChatHandler::sendRaw(const std::string &args) const line = line.substr(pos + 1); pos = line.find(" "); } - if (line != "") + if (!line.empty()) processRaw(*outMsg, line); delete outMsg; } |