mirror of
https://github.com/vdemydiuk/mtapi.git
synced 2026-08-17 12:48:11 +00:00
Small fix in MtService
This commit is contained in:
@@ -181,9 +181,10 @@ void MtServer::OnAccept(boost::beast::error_code ec,
|
|||||||
auto command = ParseCommand(msg);
|
auto command = ParseCommand(msg);
|
||||||
if (command)
|
if (command)
|
||||||
{
|
{
|
||||||
if (experts_.count(command->getExpertHandle()) > 0)
|
auto expert_handle = command->getExpertHandle();
|
||||||
|
if (experts_.count(expert_handle) > 0)
|
||||||
{
|
{
|
||||||
experts_[command->getExpertHandle()]->expert->Process(std::move(command), [&](const MtResponse& response) {
|
experts_[expert_handle]->expert->Process(std::move(command), [&](const MtResponse& response) {
|
||||||
auto connection = con.lock();
|
auto connection = con.lock();
|
||||||
if (connection)
|
if (connection)
|
||||||
connection->Send(response.Serialize());
|
connection->Send(response.Serialize());
|
||||||
|
|||||||
Reference in New Issue
Block a user