mirror of
https://github.com/SWG-Source/src.git
synced 2026-08-01 01:16:03 -04:00
catch any stupid or lazy mistakes that could be made...
This commit is contained in:
@@ -244,7 +244,14 @@ void ClientConnection::validateClient(const std::string & id, const std::string
|
||||
}
|
||||
else
|
||||
{
|
||||
ErrorMessage err("Login Failed", j["userMessage"]);
|
||||
std::string errMsg = j["userMessage"];
|
||||
|
||||
if (errMsg.empty()) //prevent stupid mistakes
|
||||
{
|
||||
errMsg = "Error: authentication service provided no user message.";
|
||||
}
|
||||
|
||||
ErrorMessage err("Login Failed", errMsg);
|
||||
this->send(err, true);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user